Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Hooke
/
tswj
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
hookehuyr
2022-05-31 12:02:49 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
3e976a68e6b5fc6b56444fef50f1b1dc411f161c
3e976a68
1 parent
50b07b03
🌈 style:
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
50 deletions
.gitignore
src/App.vue
src/main.js
yarn.lock
.gitignore
View file @
3e976a6
...
...
@@ -12,3 +12,4 @@ src/store/test.js
cypress
src/test/mocha/test.js
cypress.json
src/test
...
...
src/App.vue
View file @
3e976a6
<!--
* @Author: hookehuyr hookehuyr@gmail.com
* @Date: 2022-05-26 23:52:36
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-05-31 10:09:23
* @FilePath: /tswj/src/App.vue
* @Description:
-->
<template>
<!-- 页面缓存 -->
<router-view v-slot="{ Component, route }">
...
...
@@ -17,9 +25,7 @@ import vConsole from '@/utils/vconsole'
//
使用
include
+
pinia
状态管理动态缓存页面
const
store
=
mainStore
()
const
keepPages
=
computed
(()
=
>
{
return
store
.
getKeepPages
})
const
keepPages
=
computed
(()
=
>
store
.
getKeepPages
)
//
设置页面标题
const
$route
=
useRoute
();
...
...
@@ -28,6 +34,7 @@ watchEffect(
useTitle
(
$route
.
meta
.
title
)
}
)
</script>
<style lang="less">
...
...
src/main.js
View file @
3e976a6
...
...
@@ -12,36 +12,7 @@ const app = createApp(App);
app
.
config
.
globalProperties
.
$http
=
axios
;
// 关键语句
app
.
use
(
pinia
);
app
.
use
(
router
);
app
.
use
(
Button
);
app
.
use
(
VanImage
);
app
.
use
(
Col
);
app
.
use
(
Row
);
app
.
use
(
Icon
);
app
.
use
(
Form
);
app
.
use
(
Field
);
app
.
use
(
CellGroup
);
app
.
use
(
Toast
);
app
.
use
(
Uploader
);
app
.
use
(
Empty
);
app
.
use
(
Tab
);
app
.
use
(
Tabs
);
app
.
use
(
Overlay
);
app
.
use
(
NumberKeyboard
);
app
.
use
(
Lazyload
);
app
.
use
(
List
);
app
.
use
(
PullRefresh
);
app
.
use
(
Popup
);
app
.
use
(
Picker
);
app
.
use
(
Sticky
);
app
.
use
(
Stepper
);
app
.
use
(
Tag
);
app
.
use
(
Swipe
);
app
.
use
(
SwipeItem
);
app
.
use
(
Dialog
);
app
.
use
(
ActionSheet
);
app
.
use
(
Loading
);
app
.
use
(
pinia
).
use
(
router
).
use
(
Button
).
use
(
VanImage
).
use
(
Col
).
use
(
Row
).
use
(
Icon
).
use
(
Form
).
use
(
Field
).
use
(
CellGroup
).
use
(
Toast
).
use
(
Uploader
).
use
(
Empty
).
use
(
Tab
).
use
(
Tabs
).
use
(
Overlay
).
use
(
NumberKeyboard
).
use
(
Lazyload
).
use
(
List
).
use
(
PullRefresh
).
use
(
Popup
).
use
(
Picker
).
use
(
Sticky
).
use
(
Stepper
).
use
(
Tag
).
use
(
Swipe
).
use
(
SwipeItem
).
use
(
Dialog
).
use
(
ActionSheet
).
use
(
Loading
);
app
.
use
(
ConfigProvider
);
...
...
yarn.lock
View file @
3e976a6
...
...
@@ -221,7 +221,7 @@
"@vue/compiler-core" "3.2.36"
"@vue/shared" "3.2.36"
"@vue/compiler-sfc@3.2.36", "@vue/compiler-sfc@^3.2.31":
"@vue/compiler-sfc@3.2.36", "@vue/compiler-sfc@^3.2.31"
, "@vue/compiler-sfc@^3.2.36"
:
version "3.2.36"
resolved "https://mirrors.tencent.com/npm/@vue%2fcompiler-sfc/-/compiler-sfc-3.2.36.tgz#e5065e7c0e5170ffa750e3c3dd93a29db109d0f2"
integrity sha512-AvGb4bTj4W8uQ4BqaSxo7UwTEqX5utdRSMyHy58OragWlt8nEACQ9mIeQh3K4di4/SX+41+pJrLIY01lHAOFOA==
...
...
@@ -237,22 +237,6 @@
postcss "^8.1.10"
source-map "^0.6.1"
"@vue/compiler-sfc@^3.2.36":
version "3.2.36"
resolved "https://mirrors.cloud.tencent.com/npm/@vue%2fcompiler-sfc/-/compiler-sfc-3.2.36.tgz#e5065e7c0e5170ffa750e3c3dd93a29db109d0f2"
integrity sha512-AvGb4bTj4W8uQ4BqaSxo7UwTEqX5utdRSMyHy58OragWlt8nEACQ9mIeQh3K4di4/SX+41+pJrLIY01lHAOFOA==
dependencies:
"@babel/parser" "^7.16.4"
"@vue/compiler-core" "3.2.36"
"@vue/compiler-dom" "3.2.36"
"@vue/compiler-ssr" "3.2.36"
"@vue/reactivity-transform" "3.2.36"
"@vue/shared" "3.2.36"
estree-walker "^2.0.2"
magic-string "^0.25.7"
postcss "^8.1.10"
source-map "^0.6.1"
"@vue/compiler-ssr@3.2.36":
version "3.2.36"
resolved "https://mirrors.tencent.com/npm/@vue%2fcompiler-ssr/-/compiler-ssr-3.2.36.tgz#314f3a9424db58142c3608f48cbda7aa05fc66cb"
...
...
Please
register
or
login
to post a comment