<template>
	<view class="content">
		
	</view>
</template>

<script>
	export default {
		data() {
			return {
				src: '',
				isFlag: true
			}
		},
		onHide() {
			uni.setStorageSync('isFlag', false)
		},
		onShow() {
			this.gotoPath()
		},
		methods: {
			gotoPath() {
				this.isFlag = uni.getStorageSync('isFlag')
				if(this.isFlag) {
					uni.navigateTo({
						url: "plugin://myPlugin/index"
					})
				}else {
					uni.switchTab({
						url: '/pages/index/index'
					})
				}
			}
		}
	}
</script>

<style lang="scss" scoped>
	.content {
		width: 100vw;
		height: 100vh;
		padding-bottom: env(safe-area-inset-bottom);
		padding-top: 100rpx;
		text-align: center;
	}
</style>