build: add momentjs

This commit is contained in:
Gauthier Roebroeck 2020-03-12 17:59:16 +08:00
parent 3176cd2858
commit c6ac3beabe
3 changed files with 21 additions and 0 deletions

View file

@ -11951,6 +11951,12 @@
"integrity": "sha512-3j8wdDzYuWO3lM3Reg03MuQR957t287Rpcxp1njpEa8oDrikb+FwGdW3n+FELh/A6qib6yPit0j/pv9G/yeAqA==", "integrity": "sha512-3j8wdDzYuWO3lM3Reg03MuQR957t287Rpcxp1njpEa8oDrikb+FwGdW3n+FELh/A6qib6yPit0j/pv9G/yeAqA==",
"dev": true "dev": true
}, },
"lodash.difference": {
"version": "4.5.0",
"resolved": "https://registry.npmjs.org/lodash.difference/-/lodash.difference-4.5.0.tgz",
"integrity": "sha1-nMtOUF1Ia5FlE0V3KIWi3yf9AXw=",
"dev": true
},
"lodash.foreach": { "lodash.foreach": {
"version": "4.5.0", "version": "4.5.0",
"resolved": "https://registry.npmjs.org/lodash.foreach/-/lodash.foreach-4.5.0.tgz", "resolved": "https://registry.npmjs.org/lodash.foreach/-/lodash.foreach-4.5.0.tgz",
@ -12419,6 +12425,15 @@
"resolved": "https://registry.npmjs.org/moment/-/moment-2.24.0.tgz", "resolved": "https://registry.npmjs.org/moment/-/moment-2.24.0.tgz",
"integrity": "sha512-bV7f+6l2QigeBBZSM/6yTNq4P2fNpSWj/0e7jQcy87A8e7o2nAfP/34/2ky5Vw4B9S446EtIhodAzkFCcR4dQg==" "integrity": "sha512-bV7f+6l2QigeBBZSM/6yTNq4P2fNpSWj/0e7jQcy87A8e7o2nAfP/34/2ky5Vw4B9S446EtIhodAzkFCcR4dQg=="
}, },
"moment-locales-webpack-plugin": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/moment-locales-webpack-plugin/-/moment-locales-webpack-plugin-1.1.2.tgz",
"integrity": "sha512-s+JE7lADQjUyeQvqB3sVcfxXncg1o+t5hrRl2GBY66vXuLO2tXIjD+4mNUXQMS10qCGoeK3R3skBrW34gHobBQ==",
"dev": true,
"requires": {
"lodash.difference": "^4.5.0"
}
},
"move-concurrently": { "move-concurrently": {
"version": "1.0.1", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/move-concurrently/-/move-concurrently-1.0.1.tgz", "resolved": "https://registry.npmjs.org/move-concurrently/-/move-concurrently-1.0.1.tgz",

View file

@ -13,6 +13,7 @@
"core-js": "^3.6.4", "core-js": "^3.6.4",
"jquery": "^3.4.1", "jquery": "^3.4.1",
"lodash": "^4.17.15", "lodash": "^4.17.15",
"moment": "^2.24.0",
"qs": "^6.9.1", "qs": "^6.9.1",
"vue": "^2.6.11", "vue": "^2.6.11",
"vue-cookies": "^1.6.1", "vue-cookies": "^1.6.1",
@ -45,6 +46,7 @@
"eslint": "^5.16.0", "eslint": "^5.16.0",
"eslint-plugin-vue": "^5.0.0", "eslint-plugin-vue": "^5.0.0",
"html-webpack-inject-attributes-plugin": "^1.0.2", "html-webpack-inject-attributes-plugin": "^1.0.2",
"moment-locales-webpack-plugin": "^1.1.2",
"sass": "^1.25.0", "sass": "^1.25.0",
"sass-loader": "^8.0.2", "sass-loader": "^8.0.2",
"ts-jest": "^25.2.1", "ts-jest": "^25.2.1",

View file

@ -1,4 +1,5 @@
const htmlInject = require('html-webpack-inject-attributes-plugin') const htmlInject = require('html-webpack-inject-attributes-plugin')
const momentLocalesPlugin = require('moment-locales-webpack-plugin')
const _ = require('lodash') const _ = require('lodash')
// vue.config.js // vue.config.js
@ -29,5 +30,8 @@ module.exports = {
config.plugin('html-inject') config.plugin('html-inject')
.after('html') .after('html')
.use(htmlInject) .use(htmlInject)
config.plugin('momentLocalesPlugin')
.use(momentLocalesPlugin)
} }
} }