improve dist chunks structure

Moving all js assets into _nuxt/js and css assets into _nuxt/css
This commit is contained in:
Pooya Parsa 2017-12-29 13:15:21 +03:30
parent bfe1f2c4d3
commit d243ad13e1
2 changed files with 6 additions and 6 deletions

View File

@ -154,11 +154,11 @@ Options.defaults = {
uglify: {}, uglify: {},
publicPath: '/_nuxt/', publicPath: '/_nuxt/',
filenames: { filenames: {
css: 'vendor.[contenthash].css', css: 'css/[name].[contenthash].css',
manifest: 'manifest.[hash].js', manifest: 'js/manifest.[hash].js',
vendor: 'vendor.[chunkhash].js', vendor: 'js/vendor.[chunkhash].js',
app: 'app.[chunkhash].js', app: 'js/app.[chunkhash].js',
chunk: '[name].[chunkhash].js' chunk: 'js/[name].[chunkhash].js'
}, },
vendor: [], vendor: [],
plugins: [], plugins: [],

View File

@ -54,7 +54,7 @@ test('/ (custom app.html)', async t => {
test('/ (custom build.publicPath)', async t => { test('/ (custom build.publicPath)', async t => {
const { html } = await nuxt.renderRoute('/') const { html } = await nuxt.renderRoute('/')
t.true(html.includes('src="/test/orion/vendor.')) t.true(html.includes('src="/test/orion/js/vendor.'))
}) })
test('/ (custom postcss.config.js)', async t => { test('/ (custom postcss.config.js)', async t => {