Skip to content

Commit

Permalink
chore: lint
Browse files Browse the repository at this point in the history
  • Loading branch information
leedom92 committed Aug 23, 2023
1 parent 2458ac5 commit 755e530
Show file tree
Hide file tree
Showing 6 changed files with 96 additions and 96 deletions.
26 changes: 13 additions & 13 deletions fixtures/vue-h5-template/src/components/TabBar/index.vue
Original file line number Diff line number Diff line change
@@ -1,18 +1,5 @@
/** * Created by Leedom on 2022-11-16 01:46:11 */

<template>
<van-tabbar v-model="active">
<van-tabbar-item
v-for="(item, $index) in routes"
:key="$index"
replace
:name="item.name"
:to="item.path"
:icon="item.meta.icon"
>{{ item.meta.title }}</van-tabbar-item>
</van-tabbar>
</template>

<script>
export default {
name: 'TabBar',
Expand All @@ -35,4 +22,17 @@ export default {
}
</script>

<template>
<van-tabbar v-model="active">
<van-tabbar-item
v-for="(item, $index) in routes"
:key="$index"
replace
:name="item.name"
:to="item.path"
:icon="item.meta.icon"
>{{ item.meta.title }}</van-tabbar-item>
</van-tabbar>
</template>

<style scoped lang="scss"></style>
26 changes: 13 additions & 13 deletions fixtures/vue-h5-template/src/layout/index.vue
Original file line number Diff line number Diff line change
@@ -1,18 +1,5 @@
/** * Created by Leedom on 2022-11-16 01:33:28 */

<template>
<div>
<keep-alive v-if="$route.meta.keepAlive">
<router-view />
</keep-alive>
<router-view v-else />
<tab-bar
v-if="$route.meta.show"
:routes="routeList"
/>
</div>
</template>

<script>
import TabBar from '_c/TabBar/index.vue'
import { basicRoutes } from '@/router/router.config'
Expand All @@ -34,4 +21,17 @@ export default {
}
</script>

<template>
<div>
<keep-alive v-if="$route.meta.keepAlive">
<router-view />
</keep-alive>
<router-view v-else />
<tab-bar
v-if="$route.meta.show"
:routes="routeList"
/>
</div>
</template>

<style scoped lang="scss"></style>
48 changes: 24 additions & 24 deletions fixtures/vue-h5-template/src/views/center/index.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,29 @@
/** * Created by Leedom on 2022-11-16 01:15:00 */

<script>
import { mapState, mapActions } from 'pinia'
import { useUserStore } from '@/store/user'
export default {
name: 'CenterComponent',
components: {},
mixins: [],
props: {},
data() {
return {}
},
computed: {
...mapState(useUserStore, ['author', 'github', 'homepage']),
},
watch: {},
created() {},
mounted() {},
methods: {
...mapActions(useUserStore, ['greet']),
},
}
</script>

<template>
<div class="center">
<div class="flex flex-col justify-center items-center min-h-screen">
Expand Down Expand Up @@ -30,28 +54,4 @@
</div>
</template>

<script>
import { mapState, mapActions } from 'pinia'
import { useUserStore } from '@/store/user'
export default {
name: 'CenterComponent',
components: {},
mixins: [],
props: {},
data() {
return {}
},
computed: {
...mapState(useUserStore, ['author', 'github', 'homepage']),
},
watch: {},
created() {},
mounted() {},
methods: {
...mapActions(useUserStore, ['greet']),
},
}
</script>

<style scoped lang="scss"></style>
18 changes: 9 additions & 9 deletions fixtures/vue-h5-template/src/views/error-page/404.vue
Original file line number Diff line number Diff line change
@@ -1,14 +1,5 @@
/** * Created by Leedom on 2022-11-16 01:32:55 */

<template>
<div class="no-page">
<div class="flex flex-col justify-center items-center">
<h1>404</h1>
<p>{{ time }}秒后回到首页</p>
</div>
</div>
</template>

<script>
export default {
name: 'Error404Component',
Expand Down Expand Up @@ -41,6 +32,15 @@ export default {
}
</script>

<template>
<div class="no-page">
<div class="flex flex-col justify-center items-center">
<h1>404</h1>
<p>{{ time }}秒后回到首页</p>
</div>
</div>
</template>

<style scoped lang="scss">
.no-page {
padding-top: 40vh;
Expand Down
40 changes: 20 additions & 20 deletions fixtures/vue-h5-template/src/views/home/index.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,25 @@
/** * Created by Leedom on 2022-11-16 01:14:18 */

<script>
import { login } from '_a/user'
export default {
name: 'HomeComponent',
components: {},
mixins: [],
props: {},
data() {
return {}
},
computed: {},
watch: {},
created() {
login({ username: 'leedom', code: '6666' })
},
mounted() {},
methods: {},
}
</script>

<template>
<div class="home p-4">
<h1 class="py-2">
Expand Down Expand Up @@ -42,26 +62,6 @@
</div>
</template>

<script>
import { login } from '_a/user'
export default {
name: 'HomeComponent',
components: {},
mixins: [],
props: {},
data() {
return {}
},
computed: {},
watch: {},
created() {
login({ username: 'leedom', code: '6666' })
},
mounted() {},
methods: {},
}
</script>

<style scoped lang="scss">
.home :deep() {
h1 {
Expand Down
34 changes: 17 additions & 17 deletions fixtures/vue-h5-template/src/views/vue/index.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
/** * Created by Leedom on 2022-11-17 07:49:19 */

<script>
export default {
name: 'VueComponent',
components: {},
mixins: [],
props: {},
data() {
return {}
},
computed: {},
watch: {},
created() {},
mounted() {},
methods: {},
}
</script>

<template>
<div class="vue h-screen flex flex-col items-center justify-center">
<img
Expand All @@ -26,21 +43,4 @@
</div>
</template>

<script>
export default {
name: 'VueComponent',
components: {},
mixins: [],
props: {},
data() {
return {}
},
computed: {},
watch: {},
created() {},
mounted() {},
methods: {},
}
</script>

<style scoped lang="scss"></style>

0 comments on commit 755e530

Please sign in to comment.