mirror of
https://github.com/tenrok/vue-ganttastic.git
synced 2026-06-08 22:32:24 +03:00
25 lines
536 B
JavaScript
25 lines
536 B
JavaScript
const isBuildLib =
|
|
(process.env.npm_lifecycle_script || '').indexOf('--target lib') > 0
|
|
|
|
module.exports = {
|
|
publicPath: '',
|
|
outputDir: isBuildLib ? 'dist' : 'demo',
|
|
css: {
|
|
loaderOptions: {
|
|
sass: {
|
|
implementation: require('sass')
|
|
}
|
|
},
|
|
extract: true
|
|
},
|
|
productionSourceMap: false,
|
|
chainWebpack: config => {
|
|
if (process.env.VUE_CLI_BUILD_TARGET === 'lib') {
|
|
config.externals({
|
|
...config.get('externals'),
|
|
moment: 'moment'
|
|
})
|
|
}
|
|
}
|
|
}
|