Skip to content

Commit

Permalink
ci: add svgo-loader , add webpack build stat
Browse files Browse the repository at this point in the history
  • Loading branch information
BoBoooooo committed Apr 15, 2021
1 parent 7d76409 commit 4a8be06
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
3 changes: 0 additions & 3 deletions build/config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
const path = require('path');
const fs = require('fs');

let externals = {};

externals = [
Object.assign({
Expand Down
7 changes: 6 additions & 1 deletion build/webpack.component.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@ const { name, version, author, homepage } = require('../package');
const webpackConfig = {
mode: 'production',
entry: Components,
stats: {
assets: true,
modules: false,
entrypoints: false,
},
output: {
path: path.resolve(process.cwd(), 'lib'),
publicPath: '/dist/',
Expand All @@ -30,7 +35,6 @@ const webpackConfig = {
performance: {
hints: false,
},
stats: 'none',
optimization: {
minimize: true,
},
Expand Down Expand Up @@ -77,6 +81,7 @@ const webpackConfig = {
symbolId: 'icon-[name]',
},
},
{ loader: 'svgo-loader', options: {} },
],
},
{
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@
"start": "vue-cli-service serve",
"build": "vue-cli-service build",
"lint": "vue-cli-service lint",
"report": "cross-env IS_REPORT=true vue-cli-service build --target lib --name ProCrud --dest lib src/index.ts",
"report": "cross-env IS_REPORT=true npm run webpack",
"log": "conventional-changelog --config ./node_modules/vue-cli-plugin-commitlint/lib/log -i CHANGELOG.md -s -r 0",
"cz": "npm run log && git add . && git cz",
"bundle": "cross-env IS_REPORT=true webpack --config build/webpack.component.js",
"bundle": "webpack --config build/webpack.component.js",
"deploy": "npm run bundle && npm publish",
"deploy:beta": "npm run bundle && npm publish --tag=beta"
},
Expand Down Expand Up @@ -79,17 +79,17 @@
"sass-loader": "^7.1.0",
"style-loader": "^2.0.0",
"svg-sprite-loader": "^4.1.6",
"svgo-loader": "2.2.1",
"svgo-loader": "^2.2.1",
"terser-webpack-plugin": "^1.2.4",
"ts-loader": "^8.1.0",
"typescript": "~3.8.3",
"vue": "2.6.11",
"vue-awesome": "^3.5.4",
"vue-property-decorator": "^8.5.0",
"vue-class-component": "^7.2.3",
"vue-cli-plugin-axios": "0.0.4",
"vue-cli-plugin-commitlint": "^1.0.12",
"vue-loader": "^15.9.6",
"vue-property-decorator": "^8.5.0",
"vue-router": "3.4.3",
"vue-template-compiler": "^2.6.11",
"vuedraggable": "^2.23.2",
Expand Down

0 comments on commit 4a8be06

Please sign in to comment.