cna-template
Advanced tools
Comparing version 2.15.0 to 3.0.0
{ | ||
"name": "cna-template", | ||
"version": "2.15.0", | ||
"version": "3.0.0", | ||
"description": "Templates for Create Nuxt App.", | ||
@@ -8,8 +8,3 @@ "files": [ | ||
], | ||
"authors": [ | ||
"Egoist <0x142857@gmail.com>", | ||
"Nuxt team <team@nuxtjs.org>", | ||
"Clark Du <clark.duxin@gmail.com>" | ||
], | ||
"license": "MIT" | ||
} |
@@ -7,7 +7,2 @@ module.exports = { | ||
}, | ||
<%_ if (server === 'adonis') { _%> | ||
globals: { | ||
use: true | ||
}, | ||
<%_ } _%> | ||
<%_ if (!typescript) { _%> | ||
@@ -29,15 +24,17 @@ parserOptions: { | ||
<%_ } _%> | ||
<%_ if (test === 'webdriverio') { _%> | ||
'plugin:wdio/recommended', | ||
<%_ } _%> | ||
'plugin:nuxt/recommended' | ||
], | ||
<%_ if (prettier) { _%> | ||
plugins: [ | ||
'prettier' | ||
<%_ if (prettier) {_%> | ||
'prettier', | ||
<%_ } _%> | ||
<%_ if (test === 'webdriverio') { _%> | ||
'wdio' | ||
<%_ } _%> | ||
], | ||
<%_ } _%> | ||
// add your custom rules here | ||
rules: { | ||
<%_ if (!esm){ _%> | ||
'nuxt/no-cjs-in-config': 'off' | ||
<%_ } _%> | ||
} | ||
rules: {} | ||
} |
@@ -5,9 +5,4 @@ { | ||
"paths": { | ||
<%_ if (server === 'adonis') { _%> | ||
"~/*": ["./resources/*"], | ||
"@/*": ["./resources/*"], | ||
<%_ } else { _%> | ||
"~/*": ["./*"], | ||
"@/*": ["./*"], | ||
<%_ } _%> | ||
"~~/*": ["./*"], | ||
@@ -14,0 +9,0 @@ "@@/*": ["./*"] |
{ | ||
"name": "<%= name %>", | ||
"version": "1.0.0", | ||
"description": "<%= description %>", | ||
"author": "<%= author %>", | ||
"private": true, | ||
"scripts": { | ||
<%_ if (server === 'none') { _%> | ||
<%_ if (tsRuntime) { _%> | ||
"dev": "nuxt-ts", | ||
"build": "nuxt-ts build", | ||
"generate": "nuxt-ts generate", | ||
"start": "nuxt-ts start", | ||
<%_ } else { _%> | ||
"dev": "nuxt", | ||
"build": "nuxt build", | ||
"start": "nuxt start", | ||
"generate": "nuxt generate", | ||
<%_ } _%> | ||
<%_ } else if (server === 'adonis') { _%> | ||
"serve:dev": "<%= pmRun %> dev", | ||
"dev": "nodemon --watch app --watch bootstrap --watch config --watch .env -x node server.js", | ||
"build": "cross-env NODE_ENV=production node ./ace nuxtbuild", | ||
"start": "cross-env NODE_ENV=production node server.js", | ||
<%_ } else { _%> | ||
"dev": "cross-env NODE_ENV=development nodemon server/index.js --watch server", | ||
"build": "nuxt build", | ||
"start": "cross-env NODE_ENV=production node server/index.js", | ||
"generate": "nuxt generate", | ||
<%_ } _%> | ||
<%_ if (ui === 'framevuerk') { _%> | ||
"build:framevuerk": "framevuerk-builder -c ./framevuerk-config.js", | ||
"prepublish": "<%= pmRun %> build:framevuerk", | ||
<%_ } _%> | ||
<%_ if (eslint) { _%> | ||
"lint": "eslint --ext .js,.vue --ignore-path .gitignore .", | ||
<%_ } _%> | ||
<%_ if (test === 'ava') { _%> | ||
"test": "<%= test %>", | ||
"test:unit": "cross-env TEST=unit ava ./test/specs/**/*", | ||
"test:e2e": "cross-env TEST=e2e ava ./test/e2e/**/*", | ||
<%_ } else if (test !== 'none') { _%> | ||
"test": "<%= test %>", | ||
<%_ } _%> | ||
"": "" | ||
}, | ||
<%_ if (lintStaged) { _%> | ||
"lint-staged": { | ||
<%_ if (eslint) { _%> | ||
"*.{js,vue}": "<%= pmRun %> lint"<%= stylelint ? "," : "" %> | ||
<%_ } _%> | ||
<%_ if (stylelint) { _%> | ||
"*.{css,vue}": "stylelint" | ||
<%_ } _%> | ||
}, | ||
"husky": { | ||
"hooks": { | ||
"pre-commit": "lint-staged" | ||
} | ||
}, | ||
<%_ } _%> | ||
"dependencies": { | ||
<%_ if (edge) { _%> | ||
"nuxt-edge": "latest", | ||
<%_ } else { _%> | ||
"nuxt": "^2.0.0", | ||
<%_ } _%> | ||
<%_ if (tsRuntime) { _%> | ||
"@nuxt/typescript-runtime": "^0.4.0", | ||
<%_ } _%> | ||
<%_ if (server !== 'none') { _%> | ||
"cross-env": "^5.2.0", | ||
<%_ } _%> | ||
<%_ if (server === 'express') { _%> | ||
"express": "^4.16.4", | ||
<%_ } else if (server === 'koa') { _%> | ||
"koa": "^2.6.2", | ||
<%_ } else if (server === 'hapi') { _%> | ||
"@hapi/hapi": "^18.3.1", | ||
"@nuxtjs/hapi": "^2.2.1", | ||
<%_ } else if (server === 'micro') { _%> | ||
"micro": "^9.3.3", | ||
"micro-route": "^2.5.0", | ||
<%_ } else if (server === 'fastify') { _%> | ||
"fastify": "^2.13.0", | ||
<%_ } else if (server === 'feathers') { _%> | ||
"@feathersjs/feathers": "^3.3.1", | ||
"@feathersjs/express": "^1.3.1", | ||
"@feathersjs/configuration": "^2.0.6", | ||
<%_ } else if (server === 'adonis') { _%> | ||
"@adonisjs/ace": "^4.0.7", | ||
"@adonisjs/auth": "^2.0.10", | ||
"@adonisjs/bodyparser": "^1.0.8", | ||
"@adonisjs/cors": "^1.0.2", | ||
"@adonisjs/fold": "^4.0.5", | ||
"@adonisjs/framework": "^4.0.27", | ||
"@adonisjs/ignitor": "^1.0.14", | ||
"@adonisjs/lucid": "^4.0.22", | ||
"@adonisjs/session": "^1.0.19", | ||
"@adonisjs/shield": "^1.0.4", | ||
<%_ } _%> | ||
<%_ if (ui === 'bootstrap') { _%> | ||
"bootstrap-vue": "^2.0.0", | ||
"bootstrap": "^4.1.3", | ||
<%_ } else if (ui === 'bulma') { _%> | ||
"@nuxtjs/bulma": "^1.2.1", | ||
<%_ } else if (ui === 'element-ui') { _%> | ||
"element-ui": "^2.4.11", | ||
<%_ } else if (ui === 'ant-design-vue') { _%> | ||
"ant-design-vue": "^1.1.10", | ||
<%_ } else if (ui === 'buefy') { _%> | ||
"nuxt-buefy": "^0.3.2", | ||
<%_ } else if (ui === 'iview') { _%> | ||
"iview": "^3.1.5", | ||
<%_ } else if (ui === 'framevuerk') { _%> | ||
"framevuerk": "^2.2.5", | ||
<%_ } else if (ui === 'vuesax') { _%> | ||
"vuesax": "^4.0.1-alpha.8", | ||
<%_ } _%> | ||
<%_ if (axios) { _%> | ||
"@nuxtjs/axios": "^5.3.6", | ||
<%_ } _%> | ||
<%_ if (pwa) { _%> | ||
"@nuxtjs/pwa": "^3.0.0-0", | ||
<%_ } _%> | ||
<%_ if (dotenv) { _%> | ||
"@nuxtjs/dotenv": "^1.4.0", | ||
<%_ } _%> | ||
<%_ if (ui === 'tachyons') { _%> | ||
"tachyons": "^4.11.1", | ||
<%_ } _%> | ||
"": "" | ||
}, | ||
"devDependencies": { | ||
<%_ if (server !== 'none') { _%> | ||
"nodemon": "^1.18.9", | ||
<%_ } _%> | ||
<%_ if (typescript) { _%> | ||
"@nuxt/typescript-build": "^0.6.0", | ||
<%_ } _%> | ||
<%_ if (ui === 'tailwind') { _%> | ||
"@nuxtjs/tailwindcss": "^1.0.0", | ||
<%_ } else if (ui === 'vuetify') { _%> | ||
"@nuxtjs/vuetify": "^1.0.0", | ||
<%_ } else if (ui === 'framevuerk') { _%> | ||
"framevuerk-builder": "^2.0.2", | ||
<%_ } _%> | ||
<%_ if (eslint) { _%> | ||
<%_ if (typescript) { _%> | ||
"@nuxtjs/eslint-config-typescript": "^1.0.0", | ||
<%_ } else { _%> | ||
"@nuxtjs/eslint-config": "^2.0.0", | ||
<%_ } _%> | ||
"@nuxtjs/eslint-module": "^1.0.0", | ||
"babel-eslint": "^10.0.1", | ||
"eslint": "^6.1.0", | ||
"eslint-plugin-nuxt": ">=0.4.2", | ||
<%_ } _%> | ||
<%_ if (prettier) { _%> | ||
"eslint-config-prettier": "^6.10.0", | ||
"eslint-plugin-prettier": "^3.1.2", | ||
"prettier": "^1.19.1", | ||
<%_ } _%> | ||
<%_ if (lintStaged) { _%> | ||
"husky": "^4.0.0", | ||
"lint-staged": "^10.0.0", | ||
<%_ } _%> | ||
<%_ if (stylelint) { _%> | ||
"@nuxtjs/stylelint-module": "^3.1.0", | ||
"stylelint": "^10.1.0", | ||
<%_ } _%> | ||
<%_ if (test !== 'none') { _%> | ||
"@vue/test-utils": "^1.0.0-beta.27", | ||
<%_ } _%> | ||
<%_ if (test === 'jest') { _%> | ||
"babel-jest": "^24.1.0", | ||
"jest": "^24.1.0", | ||
"vue-jest": "^4.0.0-0", | ||
<%_ if (typescript) { _%> | ||
"ts-jest": "^25.0.0", | ||
<%_ } _%> | ||
<%_ } else if (test === 'ava') { _%> | ||
"ava": "^3.0.0", | ||
"@ava/babel": "^1.0.0", | ||
"babel-plugin-module-resolver": "^3.2.0", | ||
"browser-env": "^3.2.5", | ||
"require-extension-hooks": "^0.3.3", | ||
"require-extension-hooks-babel": "^1.0.0", | ||
"require-extension-hooks-vue": "^2.0.0", | ||
<%_ } _%> | ||
"": "" | ||
} | ||
"private": true | ||
} |
module.exports = { | ||
extends: [ | ||
'stylelint-config-standard', | ||
<%_ if (prettier) { _%> | ||
'stylelint-config-prettier' | ||
<%_ } _%> | ||
], | ||
// add your custom config here | ||
@@ -3,0 +9,0 @@ // https://stylelint.io/user-guide/configuration |
@@ -1,11 +0,15 @@ | ||
require('browser-env')() | ||
const hooks = require('require-extension-hooks') | ||
if (process.env.TEST === 'unit') { | ||
require('jsdom-global')() | ||
// https://github.com/nuxt/create-nuxt-app/issues/180#issuecomment-463069941 | ||
window.Date = global.Date = Date | ||
} | ||
const Vue = require('vue') | ||
Vue.config.productionTip = false | ||
// https://github.com/nuxt/create-nuxt-app/issues/180#issuecomment-463069941 | ||
window.Date = global.Date = Date | ||
const hooks = require('require-extension-hooks') | ||
hooks('vue').plugin('vue').push() | ||
hooks(['vue', 'js']).exclude(({ filename }) => filename.match(/\/node_modules\//)).plugin('babel').push() | ||
hooks(['vue', 'js']) | ||
.exclude(({ filename }) => filename.match(/\/node_modules\//)) | ||
.plugin('babel') | ||
.push() |
@@ -0,3 +1,3 @@ | ||
import test from 'ava' | ||
import { mount } from '@vue/test-utils' | ||
import test from 'ava' | ||
import Logo from '@/components/Logo.vue' | ||
@@ -7,3 +7,3 @@ | ||
const wrapper = mount(Logo) | ||
t.is(wrapper.isVueInstance(), true) | ||
t.truthy(wrapper.vm) | ||
}) |
@@ -7,4 +7,4 @@ import { mount } from '@vue/test-utils' | ||
const wrapper = mount(Logo) | ||
expect(wrapper.isVueInstance()).toBeTruthy() | ||
expect(wrapper.vm).toBeTruthy() | ||
}) | ||
}) |
@@ -1,26 +0,13 @@ | ||
<%_ if (esm) { _%> | ||
<%_ if (ui === 'vuetify') { _%> | ||
import colors from 'vuetify/es5/util/colors' | ||
<%_ } _%> | ||
<%_ } else { _%> | ||
<%_ if (server === 'adonis') { _%> | ||
const { resolve } = require('path') | ||
<%_ } _%> | ||
<%_ if (ui === 'vuetify') { _%> | ||
const colors = require('vuetify/es5/util/colors').default | ||
<%_ } _%> | ||
<%_ if (ui === 'vuetify') { _%>import colors from 'vuetify/es5/util/colors' | ||
<%_ } _%> | ||
<%_ if (esm) { _%> | ||
export default { | ||
<%_ } else { _%> | ||
module.exports = { | ||
<%_ } _%> | ||
/* | ||
** Nuxt rendering mode | ||
** See https://nuxtjs.org/api/configuration-mode | ||
*/ | ||
mode: '<%= mode %>', | ||
<%_ if (server === 'adonis') { _%> | ||
dev: process.env.NODE_ENV === 'development', | ||
srcDir: resolve(__dirname, '..', 'resources'), | ||
<%_ } _%> | ||
/* | ||
** Headers of the page | ||
** See https://nuxtjs.org/api/configuration-head | ||
*/ | ||
@@ -49,6 +36,2 @@ head: { | ||
/* | ||
** Customize the progress-bar color | ||
*/ | ||
loading: { color: '#fff' }, | ||
/* | ||
** Global CSS | ||
@@ -73,2 +56,3 @@ */ | ||
** Plugins to load before mounting the App | ||
** https://nuxtjs.org/guide/plugins | ||
*/ | ||
@@ -131,5 +115,5 @@ plugins: [ | ||
<%_ } _%> | ||
<%_ if (dotenv) { _%> | ||
// Doc: https://github.com/nuxt-community/dotenv-module | ||
'@nuxtjs/dotenv', | ||
<%_ if (content) { _%> | ||
// Doc: https://github.com/nuxt/content | ||
'@nuxt/content', | ||
<%_ } _%> | ||
@@ -142,5 +126,11 @@ ], | ||
*/ | ||
axios: { | ||
}, | ||
axios: {}, | ||
<%_ } _%> | ||
<%_ if (content) { _%> | ||
/* | ||
** Content module configuration | ||
** See https://content.nuxtjs.org/configuration | ||
*/ | ||
content: {}, | ||
<%_ } _%> | ||
<%_ if (ui === 'vuetify') { _%> | ||
@@ -171,2 +161,3 @@ /* | ||
** Build configuration | ||
** See https://nuxtjs.org/api/configuration-build/ | ||
*/ | ||
@@ -185,8 +176,3 @@ build: { | ||
<%_ } _%> | ||
/* | ||
** You can extend webpack config here | ||
*/ | ||
extend (config, ctx) { | ||
} | ||
} | ||
} |
# <%= name %> | ||
> <%= description %> | ||
## Build Setup | ||
@@ -6,0 +4,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 6 instances in 1 package
2
97456
81
759
21
1