feat: 还是发现会有样式污染,不妥

This commit is contained in:
Burt 2023-12-23 10:18:43 +08:00
parent 0058be3dde
commit f6d52a437c
2 changed files with 13 additions and 0 deletions

11
src/pages/index/Test.vue Normal file
View File

@ -0,0 +1,11 @@
<template>
<view class="content">
<view class="text-green-500">test</view>
</view>
</template>
<style>
.content {
font-size: 40rpx;
}
</style>

View File

@ -8,12 +8,14 @@
Demo Count: {{ countStore.count }} Demo Count: {{ countStore.count }}
<button class="ml-2" @click="countStore.increment">新增</button> <button class="ml-2" @click="countStore.increment">新增</button>
</view> </view>
<Test />
</view> </view>
</template> </template>
<script setup lang="ts" name="TestIndex"> <script setup lang="ts" name="TestIndex">
import { ref } from 'vue' import { ref } from 'vue'
import { useCountStore } from '@/store/count' import { useCountStore } from '@/store/count'
import Test from './Test.vue'
const countStore = useCountStore() const countStore = useCountStore()
const title = ref('Hello') const title = ref('Hello')