diff --git a/.browserslistrc b/.browserslistrc new file mode 100644 index 0000000..214388f --- /dev/null +++ b/.browserslistrc @@ -0,0 +1,3 @@ +> 1% +last 2 versions +not dead diff --git a/.eslintignore b/.eslintignore index 95cf0b0..178135c 100644 --- a/.eslintignore +++ b/.eslintignore @@ -1,3 +1 @@ -/build/ -/config/ -/dist/ \ No newline at end of file +/dist/ diff --git a/.eslintrc.js b/.eslintrc.js index 7c23921..50c0639 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,33 +1,34 @@ +const prod = process.env.NODE_ENV === 'production' + module.exports = { root: true, + env: { + node: true + }, + extends: [ + 'plugin:vue/strongly-recommended', + 'plugin:vue-a11y/base', + 'eslint:recommended', + '@vue/standard' + ], + plugins: [ + 'vue-a11y' + ], parserOptions: { parser: 'babel-eslint' }, - env: { - browser: true, - node: true, - mocha: true - }, - "globals": { - "expect": true - }, - extends: [ - 'plugin:vue/recommended', - 'plugin:vue-a11y/base', - 'standard' - ], - plugins: [ - 'vue', - 'vue-a11y' - ], rules: { - 'generator-star-spacing': 'off', - 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off', - 'vue/singleline-html-element-content-newline': 'off', - 'vue/multiline-html-element-content-newline': 'off', - 'vue/max-attributes-per-line': 'off', - 'vue/no-v-html': 'off', - 'vue/require-default-prop': 'off', - 'vue-a11y/label-has-for': 'off' + 'no-console': prod ? 'warn' : 'off', + 'no-debugger': prod ? 'warn' : 'off', + 'vue/max-attributes-per-line': [ + 'error', + { + singleline: 3, + multiline: { max: 3, allowFirstLine: true } + } + ], + 'no-irregular-whitespace': 'off', + 'no-unused-vars': 'warn', + 'no-multiple-empty-lines': ['error', { max: 2 }] } } diff --git a/babel.config.js b/babel.config.js new file mode 100644 index 0000000..e955840 --- /dev/null +++ b/babel.config.js @@ -0,0 +1,5 @@ +module.exports = { + presets: [ + '@vue/cli-plugin-babel/preset' + ] +} diff --git a/package.json b/package.json index 9f1769d..86c9332 100644 --- a/package.json +++ b/package.json @@ -1,77 +1,42 @@ { - "name": "vue-webpack-4", - "version": "1.1.0", - "description": "A Vuejs template using Webpack 4", - "main": "index.js", + "name": "en-francais", + "version": "0.1.0", + "license": "GPL-3.0", + "private": true, + "author": "Nicolas CHESNAIS", "scripts": { - "dev": "webpack-dev-server --progress --config build/webpack.config.dev.js", - "prod": "webpack --config build/webpack.config.prod.js", - "lint": "eslint --ext .js,.vue src", - "lint:fix": "eslint --ext .js,.vue src --fix", - "test": "jest --config test/jest.config.js", - "test:debug": "node --inspect node_modules/.bin/jest --runInBand --config test/jest.config.js" + "dev": "vue-cli-service serve", + "prod": "vue-cli-service build", + "lint": "vue-cli-service lint --no-fix", + "lint:fix": "vue-cli-service lint" }, - "keywords": [ - "Vue", - "Webpack 4" - ], - "author": "Daniel Cook", - "license": "MIT", "dependencies": { - "@popperjs/core": "^2.4.4", - "axios": "^0.18.1", - "vue": "^2.6.10", - "vue-clipboard2": "^0.3.1", - "vue-infinite-loading": "^2.4.5", - "vue-meta": "^1.6.0", - "vue-router": "^3.1.3", - "vue-scrollto": "^2.18.1", - "vue-select": "^3.10.7", - "vue2-touch-events": "^2.2.1", - "vuex": "^3.1.1", - "vuex-router-sync": "^5.0.0" + "axios": "^0.21.1", + "core-js": "^3.6.5", + "vue": "^2.6.11", + "vue-meta": "^2.4.0", + "vue-router": "^3.2.0", + "vue2-touch-events": "^3.2.0", + "vuex": "^3.4.0" }, "devDependencies": { - "@babel/core": "^7.6.0", - "@babel/preset-env": "^7.6.0", - "@vue/test-utils": "^1.0.0-beta.29", - "babel-core": "^7.0.0-bridge.0", - "babel-eslint": "^10.0.3", - "babel-jest": "^24.9.0", - "babel-loader": "^8.0.6", - "copy-webpack-plugin": "^5.0.4", - "css-loader": "^2.1.1", - "eslint": "^5.16.0", - "eslint-config-standard": "^12.0.0", - "eslint-loader": "^2.2.1", - "eslint-plugin-import": "^2.18.2", - "eslint-plugin-node": "^8.0.1", + "@vue/cli-plugin-babel": "~4.5.0", + "@vue/cli-plugin-eslint": "~4.5.0", + "@vue/cli-plugin-router": "~4.5.0", + "@vue/cli-plugin-vuex": "~4.5.0", + "@vue/cli-service": "~4.5.0", + "@vue/eslint-config-standard": "^5.1.2", + "babel-eslint": "^10.1.0", + "eslint": "^6.7.2", + "eslint-config-standard": "^16.0.2", + "eslint-plugin-import": "^2.20.2", + "eslint-plugin-node": "^11.1.0", "eslint-plugin-promise": "^4.2.1", - "eslint-plugin-standard": "^4.0.1", - "eslint-plugin-vue": "^5.2.3", - "eslint-plugin-vue-a11y": "0.0.28", - "file-loader": "^4.2.0", - "html-webpack-harddisk-plugin": "^1.0.1", - "html-webpack-plugin": "^3.2.0", - "jest": "^24.9.0", - "jest-serializer-vue": "^2.0.2", - "mini-css-extract-plugin": "^0.5.0", + "eslint-plugin-standard": "^4.0.0", + "eslint-plugin-vue": "^6.2.2", + "eslint-plugin-vue-a11y": "0.0.31", "node-sass": "^4.12.0", - "sass-loader": "^7.3.1", - "style-loader": "^0.23.1", - "stylus": "^0.54.7", - "stylus-loader": "^3.0.2", - "uglify-es": "^3.3.9", - "uglifyjs-webpack-plugin": "^2.2.0", - "url-loader": "^1.1.2", - "vue-jest": "^3.0.5", - "vue-loader": "^15.7.1", - "vue-server-renderer": "^2.6.10", - "vue-style-loader": "^4.1.2", - "vue-template-compiler": "^2.6.10", - "webpack": "^4.40.2", - "webpack-cli": "^3.3.9", - "webpack-dev-server": "^3.8.1", - "webpack-merge": "^4.2.2" + "sass-loader": "^8.0.2", + "vue-template-compiler": "^2.6.11" } } diff --git a/public/index.html b/public/index.html index 8200e8f..df52a80 100644 --- a/public/index.html +++ b/public/index.html @@ -1,11 +1,16 @@ - +
+ +contenu
-