diff options
author | tijmenvangulik <tijmen@vangulik.org> | 2021-04-10 10:34:00 +0200 |
---|---|---|
committer | tijmenvangulik <tijmen@vangulik.org> | 2021-04-10 10:34:00 +0200 |
commit | c0f30068c2f46e7015cea7e45e08bf902a2815d9 (patch) | |
tree | 4ac13bf633b5ea40cb0b9391f2883b29d442d727 /README.md | |
parent | Corrected wrong encoded unicode characters in css (diff) | |
download | tabler-icons-c0f30068c2f46e7015cea7e45e08bf902a2815d9.tar.xz |
Moved compileFonts properties from package to separate file
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 26 |
1 files changed, 18 insertions, 8 deletions
@@ -131,28 +131,38 @@ Compiling fonts: To compile fonts first install [fontforge](https://fontforge.org/en-US/) -the fontforge executable needs to be in the path or you can set set the path to the downloaded fontforge executable in the package.json. If you installed in on a mac in your application directory it will be: +When compiling the font it will look for a json file compile-options.json in root folder (same folder as the package.json) In this file you can define extra options: + +The default settings if you have not defined the file will be: +{ + "includeIcons": [], + "fontForge": "fontforge", + "strokeWidth": 2 +} + +The fontforge executable needs to be in the path or you can set set the path to the downloaded fontforge executable in the. If you installed in on a mac in your application directory it will be "/Applications/FontForge.app/Contents/MacOS/FontForge". You can set this value in the compile-options.json file. + ```JSON - "compileFonts": { + { "fontForge":"/Applications/FontForge.app/Contents/MacOS/FontForge" } ``` To compile the fonts run: npm run build-iconfont -By default the stroke width is 2. You can change the stroke width by setting the package property: +By default the stroke width is 2. You can change the stroke width in the compile-options.json ```JSON - "compileFonts": { - "strokeWidth":"1.5", + { + "strokeWidth": 1.5, } ``` -To reduce the font file size you can choose to compile a sub set of icons. When you leave the array empty it will compile all the fonts. For example: +To reduce the font file size you can choose to compile a sub set of icons. When you leave the array empty it will compile all the fonts. To compile only two icons you can set for example the folowing option in the compile-options.json: ```JSON - "includeIcons": { - "include":["alert-octagon","alert-triangle"] + { + "includeIcons":["alert-octagon","alert-triangle"] } ``` |