Add moment-locales-webpack-plugin
This commit is contained in:
parent
350360e2a9
commit
2a988275f3
1
.gitignore
vendored
1
.gitignore
vendored
@ -5,6 +5,7 @@
|
||||
/public/hot
|
||||
/public/storage
|
||||
/public/mix-manifest.json
|
||||
/public/report.html
|
||||
/storage/*.key
|
||||
/vendor
|
||||
/.idea
|
||||
|
@ -23,6 +23,7 @@
|
||||
"laravel-mix": "^4.0.0",
|
||||
"laravel-mix-bundle-analyzer": "^1.0.2",
|
||||
"lint-staged": "^8.1.5",
|
||||
"moment-locales-webpack-plugin": "^1.2.0",
|
||||
"open-iconic": "^1.1.1",
|
||||
"popper.js": "^1.14.7",
|
||||
"resolve-url-loader": "^2.3.1",
|
||||
|
10
webpack.mix.js
vendored
10
webpack.mix.js
vendored
@ -1,5 +1,6 @@
|
||||
const mix = require('laravel-mix');
|
||||
require('laravel-mix-bundle-analyzer')
|
||||
const MomentLocalesPlugin = require('moment-locales-webpack-plugin');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
@ -27,7 +28,14 @@ mix.js('resources/assets/js/app.js', 'public/js')
|
||||
.extract(['jquery', 'bootstrap'])
|
||||
.extract(['chart.js', 'chartjs-color', 'color-name', 'moment', 'd3'], 'public/js/vendor/chart')
|
||||
.version()
|
||||
.webpackConfig(webpack => ({
|
||||
plugins: [
|
||||
new MomentLocalesPlugin({
|
||||
localesToKeep: ['ja']
|
||||
})
|
||||
]
|
||||
}));
|
||||
|
||||
if (process.argv.includes('-a')) {
|
||||
mix.bundleAnalyzer({analyzerMode: 'static'});
|
||||
mix.bundleAnalyzer({ analyzerMode: 'static' });
|
||||
}
|
||||
|
12
yarn.lock
12
yarn.lock
@ -4589,6 +4589,11 @@ lodash.defaults@^4.0.0:
|
||||
resolved "https://registry.yarnpkg.com/lodash.defaults/-/lodash.defaults-4.2.0.tgz#d09178716ffea4dde9e5fb7b37f6f0802274580c"
|
||||
integrity sha1-0JF4cW/+pN3p5ft7N/bwgCJ0WAw=
|
||||
|
||||
lodash.difference@^4.5.0:
|
||||
version "4.5.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.difference/-/lodash.difference-4.5.0.tgz#9ccb4e505d486b91651345772885a2df27fd017c"
|
||||
integrity sha1-nMtOUF1Ia5FlE0V3KIWi3yf9AXw=
|
||||
|
||||
lodash.isarguments@^3.0.0:
|
||||
version "3.1.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.isarguments/-/lodash.isarguments-3.1.0.tgz#2f573d85c6a24289ff00663b491c1d338ff3458a"
|
||||
@ -5002,6 +5007,13 @@ mkdirp@^0.5.1, mkdirp@~0.5.1:
|
||||
dependencies:
|
||||
minimist "0.0.8"
|
||||
|
||||
moment-locales-webpack-plugin@^1.2.0:
|
||||
version "1.2.0"
|
||||
resolved "https://registry.yarnpkg.com/moment-locales-webpack-plugin/-/moment-locales-webpack-plugin-1.2.0.tgz#9af83876a44053706b868ceece5119584d10d7aa"
|
||||
integrity sha512-QAi5v0OlPUP7GXviKMtxnpBAo8WmTHrUNN7iciAhNOEAd9evCOvuN0g1N7ThIg3q11GLCkjY1zQ2saRcf/43nQ==
|
||||
dependencies:
|
||||
lodash.difference "^4.5.0"
|
||||
|
||||
moment@^2.10.2:
|
||||
version "2.24.0"
|
||||
resolved "https://registry.yarnpkg.com/moment/-/moment-2.24.0.tgz#0d055d53f5052aa653c9f6eb68bb5d12bf5c2b5b"
|
||||
|
Loading…
Reference in New Issue
Block a user