This switches to the maintained `grunt-webfonts` and sets options to fix the font generation by normalizing the icon sizes.
32 lines
715 B
JavaScript
32 lines
715 B
JavaScript
module.exports = function(grunt) {
|
|
grunt.loadNpmTasks("grunt-webfonts");
|
|
|
|
|
|
grunt.initConfig({
|
|
webfont: {
|
|
icons: {
|
|
src: "./*.svg",
|
|
dest: "../shell/public/icons",
|
|
destCss: "../shell/client/styles",
|
|
options: {
|
|
font: "icons",
|
|
engine: "node",
|
|
autoHint: false,
|
|
htmlDemo: false,
|
|
normalize: true,
|
|
fontHeight: 1001,
|
|
fontFilename: 'icons-{hash}',
|
|
relativeFontPath: "/icons/",
|
|
stylesheet: "scss",
|
|
templateOptions: {
|
|
classPrefix: "icon-",
|
|
mixinPrefix: "icon-",
|
|
},
|
|
},
|
|
},
|
|
},
|
|
});
|
|
|
|
grunt.registerTask("default", ["webfont"]);
|
|
};
|