<script>
    export default {
        data() {
            return {
                url: '',
            }
        },
        onLoad(options) {
            if (options.url) {
                this.url = decodeURIComponent(options.url)
            } else {
                uni.showToast({
                    title: '网址不存在',
                    icon: 'none',
                })
                uni.navigateBack()
            }
        },
    }
</script>

<template>
    <view class="webview-container">
        <web-view :src="url" />
    </view>
</template>
