-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
15 changed files
with
14,532 additions
and
104 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -58,5 +58,5 @@ typings/ | |
# dotenv environment variables file | ||
.env | ||
|
||
# next.js build output | ||
.next | ||
# nuxt.js build output | ||
.nuxt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
|
||
all: install | ||
|
||
clear: | ||
@rm -rf .nuxt | ||
@rm -rf build | ||
@rm -rf node_modules | ||
|
||
install: | ||
@npm set registry https://registry.npm.taobao.org | ||
@npm set sass_binary_site https://npm.taobao.org/mirrors/node-sass | ||
@npm install | ||
|
||
update: | ||
@npm set registry https://registry.npm.taobao.org | ||
@npm set sass_binary_site https://npm.taobao.org/mirrors/node-sass | ||
@npm update |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<template> | ||
<div> | ||
<nuxt /> | ||
</div> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
export default function () { | ||
// Add .ts extension for store, middleware and more | ||
this.nuxt.options.extensions.push('ts') | ||
// Extend build | ||
this.extendBuild((config) => { | ||
const tsLoader = { | ||
loader: 'ts-loader', | ||
options: { | ||
appendTsSuffixTo: [/\.vue$/] | ||
}, | ||
exclude: [ | ||
/dist/, | ||
/\.temp/ | ||
] | ||
} | ||
// Add TypeScript loader | ||
config.module.rules.push( | ||
Object.assign( | ||
{ | ||
test: /((client|server)\.js)|(\.tsx?)$/ | ||
}, | ||
tsLoader | ||
) | ||
) | ||
// Add .ts extension in webpack resolve | ||
if (config.resolve.extensions.indexOf('.ts') === -1) { | ||
config.resolve.extensions.push('.ts') | ||
} | ||
}) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
module.exports = { | ||
head: { | ||
title: '后台管理', | ||
meta: [ | ||
{ charset: 'uft-8' }, | ||
{ 'http-equiv': 'X-UA-Compatible', content: 'IE=Edge' } | ||
], | ||
link: [ | ||
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' } | ||
] | ||
}, | ||
modules: [ | ||
'~/modules/typescript' | ||
], | ||
css: [ | ||
'~/assets/scss/common.scss' | ||
] | ||
} |
Oops, something went wrong.