Generate Iconfont from SVG files.
$ npm install iconfont-gen --save
Options:
--src src files path pattern. [string] [default: './src/svg/*.svg']
--dest dest directory path. [string] [default: './dest/assets/fonts/']
--name font name. [string] [default: 'iconfont']
--templateInput template file path. [string] [default: __dirname + '/template/index.ejs']
--templateOutput template file output path. [string] [default: './src/scss/_iconfont.scss']
--version, -v show this version. [boolean]
--help, -h show this help. [boolean]
$ iconfont-gen --src ./src/svg/*.svg --dest ./dest/assets/fonts/ --name iconfont --templateInput ./template/index.ejs --templateOutput ./src/scss/_iconfont.scss
iconfontGen({
src: './src/svg/*.svg',
dest: './dest/assets/fonts/',
name: 'iconfont',
templateInput: './template/index.ejs',
templateOutput: './src/scss/_iconfont.scss'
}).then(() => {
console.log('Complete!!');
});