build: lang="json5" 是默认值,不用写

This commit is contained in:
Burt 2024-01-24 14:08:30 +08:00
parent 855140a1af
commit a95028f608
3 changed files with 6 additions and 5 deletions

View File

@ -20,7 +20,7 @@
"scope": "vue",
"prefix": "v3",
"body": [
"<route lang=\"json5\" type=\"page\">",
"<route type=\"page\">",
"{",
" style: { navigationBarTitleText: '$1' },",
"}",

View File

@ -1,5 +1,5 @@
<!-- 使用 type="home" 属性设置首页其他页面不需要设置默认为page推荐使用json5更强大且允许注释 -->
<route lang="json5" type="home">
<!-- type=home|page默认为page这里使用 type="home" 申明为首页其他页面不需要设置 -->
<route type="home">
{
style: {
navigationStyle: 'custom',

View File

@ -50,8 +50,9 @@ export default ({ command, mode }) => {
plugins: [
UniPages({
exclude: ['**/components/**/**.*'],
homePage: 'pages/index/index',
subPackages: ['src/pages-sub'],
// routeBlockLang: 'json5',
// homePage: 'pages/index/index',
subPackages: ['src/pages-sub'], // 是一个数组,可以设置多个
}),
UniLayouts(),
UniPlatform(),