Add svg sprite generator for icons.
This commit is contained in:
@@ -22,6 +22,7 @@
|
||||
"typings": "^0.7.12",
|
||||
"webpack": "^1.13.0",
|
||||
"webpack-dev-server": "^1.14.1",
|
||||
"webpack-svgstore-plugin": "^2.1.5",
|
||||
"xml-loader": "^1.1.0",
|
||||
"yargs": "^4.2.0",
|
||||
"zone.js": "^0.6.11"
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
// var webpack = require("webpack");
|
||||
var SvgStore = require('webpack-svgstore-plugin');
|
||||
|
||||
module.exports = {
|
||||
entry: ['reflect-metadata', 'zone.js', 'es6-shim', "./src/boot.ts"],
|
||||
@@ -21,9 +22,24 @@ module.exports = {
|
||||
loaders: [
|
||||
{ test: /\.ts$/, loader: 'ts-loader', exclude: /node_modules/ }
|
||||
]
|
||||
}/*,
|
||||
},
|
||||
plugins: [
|
||||
new webpack.optimize.UglifyJsPlugin({ minimize: true })
|
||||
]*/
|
||||
// new webpack.optimize.UglifyJsPlugin({ minimize: true })
|
||||
new SvgStore(
|
||||
[
|
||||
'images/icons/**/*.svg'
|
||||
],
|
||||
'./',
|
||||
{
|
||||
name: 'compiled_sprite.svg',
|
||||
chunk: 'app',
|
||||
svgoOptions: {
|
||||
plugins: [
|
||||
{ removeTitle: true }
|
||||
]
|
||||
}
|
||||
}
|
||||
)
|
||||
]
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user