@cnamts/vue-cli-plugin-vue-dash
Advanced tools
Comparing version 2.0.0-alpha.46 to 2.0.0-alpha.47
@@ -9,17 +9,16 @@ const vdPkg = require('../../package.json'); | ||
'@cnamts/vue-dot': `^${VueDotVersion}`, | ||
'axios': '^0.19.1', | ||
'core-js': '^3.6.2', | ||
'axios': '^0.19.2', | ||
'core-js': '^3.6.4', | ||
'dayjs': '^1.8.19', | ||
'languages': '^0.1.3', | ||
'vue-class-component': '^7.1.0', | ||
'vue-meta': '^2.3.1', | ||
'vue-meta': '^2.3.2', | ||
'vue-the-mask': '^0.11.1', | ||
'vuetify': '^2.2.3' | ||
'vuetify': '^2.2.6' | ||
}, | ||
devDependencies: { | ||
'@babel/core': '^7.7.7', | ||
'@babel/core': '^7.8.3', | ||
'@types/webfontloader': '^1.6.29', | ||
'@mdi/js': '^4.7.95', | ||
'@typescript-eslint/eslint-plugin': '^2.15.0', | ||
'@typescript-eslint/parser': '^2.15.0', | ||
'@mdi/js': '^4.8.95', | ||
'@typescript-eslint/eslint-plugin': '^2.17.0', | ||
'@typescript-eslint/parser': '^2.17.0', | ||
'babel-jest': '^24.9.0', | ||
@@ -29,2 +28,3 @@ 'jest': '^24.9.0', | ||
'ts-jest': '^24.3.0', | ||
'vue-class-component': '^7.2.2', | ||
'vue-cli-plugin-vuetify': '^2.0.3', | ||
@@ -31,0 +31,0 @@ 'vuetify-loader': '^1.4.3', |
@@ -94,3 +94,3 @@ module.exports = { | ||
{ | ||
files: ['*.vue'], | ||
files: ['*.vue', '*.js'], | ||
rules: { | ||
@@ -97,0 +97,0 @@ // The core 'no-unused-vars' rules (in the eslint:recommended ruleset) |
@@ -36,3 +36,3 @@ module.exports = { | ||
transformIgnorePatterns: [ | ||
'./node_modules/(?!vuetify)' | ||
'./node_modules/(?!vuetify|@cnamts/vue-dot)' | ||
], | ||
@@ -39,0 +39,0 @@ globals: { |
@@ -7,3 +7,3 @@ # <%= name %> | ||
Copy the file `public/js/config.js.dist` and rename it to `public/js/config.js`. | ||
This is done automatically, but if you want to setup this manually, you should copy the file `public/js/config.js.dist` and rename it to `public/js/config.js`. | ||
@@ -10,0 +10,0 @@ You can customize the variables in `config.js` if needed. |
@@ -6,2 +6,4 @@ import Vue from 'vue'; | ||
import fr from 'vuetify/src/locale/fr'; | ||
// Import theme colors | ||
@@ -21,3 +23,7 @@ import colors from '@/theme/colors'; | ||
iconfont: 'mdiSvg' | ||
}, | ||
lang: { | ||
locales: { fr }, | ||
current: 'fr' | ||
} | ||
}); |
import Vue from 'vue'; | ||
import VueRouter from 'vue-router'; | ||
@@ -80,4 +81,5 @@ import VueMeta from 'vue-meta'; | ||
<% if (i18n) { %>// Resolve translations before each navigation | ||
const lang = i18n.locale; | ||
<% if (i18n) { %>const lang = i18n.locale; | ||
// Resolve translations before each navigation | ||
loadLanguageAsync(lang).then(() => { | ||
@@ -84,0 +86,0 @@ if (MAINTENANCE === 'true') { |
@@ -18,2 +18,3 @@ import dayjs from 'dayjs'; | ||
* Format a date with time to DD/MM/YYYY HH:mm format | ||
* | ||
* @param {string} [date] The date to format | ||
@@ -20,0 +21,0 @@ * @returns {string} The formatted date |
// Global test configuration | ||
import Vue from 'vue'; | ||
import <% if (i18n) { %>VueTestUtils, <% } %>{ | ||
import VueTestUtils, | ||
createLocalVue, | ||
@@ -23,5 +23,17 @@ mount, | ||
// Create empty router and export it | ||
import VueRouter from 'vue-router'; | ||
import VueRouter, { RouterOptions } from 'vue-router'; | ||
/** Default router instance */ | ||
export const router = new VueRouter(); | ||
/** | ||
* Create a new router instance with options | ||
* | ||
* @param {RouterOptions} options The router options | ||
* @returns {VueRouter} The router instance | ||
*/ | ||
export function newRouter(options: RouterOptions) { | ||
return new VueRouter(options); | ||
} | ||
// Create localVue | ||
@@ -32,4 +44,15 @@ const localVue = createLocalVue(); | ||
import Meta from 'vue-meta'; | ||
import Vuex from 'vuex'; | ||
import Vuex, { Store, StoreOptions } from 'vuex'; | ||
/** | ||
* Create a new store instance with options | ||
* | ||
* @param {StoreOptions} options The store options | ||
* @returns {Store} The store instance | ||
*/ | ||
export function newStore(options: StoreOptions<any>): Store<any> { | ||
return new Vuex.Store(options); | ||
} | ||
// Bind plugins | ||
@@ -50,8 +73,15 @@ localVue.use(VueRouter); | ||
/** Generic build fonction */ | ||
/** | ||
* Generic mount function | ||
* | ||
* @param {VueClass} component The component to mount | ||
* @param {ShallowMountOptions|MountOptions} [options] The mount function options | ||
* @param {boolean} [fullMount] Use mount instead of shallowMount | ||
* @returns {VueTestUtils.Wrapper} The wrapper instance | ||
*/ | ||
export function mountComponent( | ||
component: VueClass<Vue>, | ||
options?: ShallowMountOptions<Vue> | MountOptions<Vue>, | ||
fullMount = false | ||
) { | ||
options: ShallowMountOptions<Vue> | MountOptions<Vue> = {}, | ||
fullMount: boolean = false | ||
): VueTestUtils.Wrapper<Vue> { | ||
// Use mount() instead of shallowMount() when fullMount is true | ||
@@ -58,0 +88,0 @@ const fn = fullMount ? mount : shallowMount; |
@@ -6,3 +6,3 @@ { | ||
"module": "esnext", | ||
// Strict type-Checking | ||
// Strict type-checking | ||
"strict": true, | ||
@@ -9,0 +9,0 @@ // Node.js resolution strategy |
@@ -15,9 +15,2 @@ const fixEnvFile = require('./fixEnvFile'); | ||
}; | ||
// Augment build command with fixEnvFile | ||
build.fn = (...args) => { | ||
fixEnvFile(); | ||
return buildFn(...args); | ||
}; | ||
}; |
{ | ||
"name": "@cnamts/vue-cli-plugin-vue-dash", | ||
"version": "2.0.0-alpha.46", | ||
"version": "2.0.0-alpha.47", | ||
"description": "Vue CLI plugin to scaffold front-end projects", | ||
@@ -23,3 +23,3 @@ "keywords": [ | ||
"dependencies": { | ||
"@cnamts/cli-helpers": "^2.0.0-alpha.46", | ||
"@cnamts/cli-helpers": "^2.0.0-alpha.47", | ||
"dayjs": "^1.8.19", | ||
@@ -32,3 +32,3 @@ "fs-extra": "^8.1.0", | ||
}, | ||
"gitHead": "b8589ed31c8fec9875f6c7db28f547299b9b022f" | ||
"gitHead": "ce7eda38f509a730aa7e1fb258201e5ffced3438" | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
178571
1658