Build optimization
parent
53cd3f560b
commit
cf86c0699b
|
@ -5,16 +5,11 @@ const vueCliServicePath = path.resolve(__dirname, 'node_modules/@vue/cli-service
|
|||
|
||||
fs.readdirSync(path.resolve(__dirname, './src/components/')).forEach(folder => {
|
||||
fs.readdirSync(path.resolve(__dirname, './src/components/' + folder)).forEach(file => {
|
||||
if (/\.vue$/.test(file)) {
|
||||
if (/\.vue$/.test(file) || /\.js$/.test(file)) {
|
||||
let filename = file.split('.vue')[0].toLowerCase();
|
||||
execSync(
|
||||
`node ${vueCliServicePath} build src/components/${folder}/${file} --target lib --name ${filename} --dest components/${folder} --no-clean `
|
||||
)
|
||||
}
|
||||
else if (/\.js$/.test(file)) {
|
||||
execSync(
|
||||
`node ${vueCliServicePath} build src/components/${folder}/${file} --target lib --name ${folder} --dest components/${folder} --no-clean `
|
||||
)
|
||||
}
|
||||
});
|
||||
});
|
|
@ -23,7 +23,6 @@ gulp.task('build-themes', function() {
|
|||
return gulp.src([
|
||||
'public/themes/**/*'
|
||||
])
|
||||
.pipe(uglifycss({"uglyComments": true}))
|
||||
.pipe(gulp.dest('resources/themes'));
|
||||
})
|
||||
|
||||
|
|
Loading…
Reference in New Issue