https://stackoverflow.com/questions/22085168/inkscape-command-line-where-is-it-on-mac
ln -s /Applications/Inkscape.app/Contents/MacOS/inkscape /usr/local/bin/inkscape
Discovered this while convering the strokes to svg path, https://github.com/leifgehrmann/svg-stroke-to-path
I faced an issue with exported SVG from Figma it had strokes but the fontforge lib won’t work with SVGs having a stroke, I had to convert those strokes to path using the Sketch tool as it was mentioned in the README.md in the dingbats project, which says
Make sure all the paths of the icons are not strokes. If there is a stroke (i.e. some border styles) convert it to path (aka Vectorize) using Sketch / Layer / Convert to Outlines menu. If not done, the fontforge won't create a glyph and the icon will be broken, even if an exported SVG file renders correctly.
In the latest version of Sketch I don’t see the option Convert to Outlines option (which was present in the older version though and I didn’t see an alternative option for the same looking online.
I found an solution using inkscape tool, with the help of this little script https://github.com/leifgehrmann/svg-stroke-to-path I was able to convert all the strokes in the SVG.
Here are the steps for those who face the similar issue in future,
- Install the inkscape app
- Link the CLI installed in Applications to /usr/local/bin folder using the below command
$ ln -s /Applications/Inkscape.app/Contents/MacOS/inkscape /usr/local/bin/inkscape
- Clone the https://github.com/leifgehrmann/svg-stroke-to-path package
- Move your .svg icon to the cloned folder (or use the relative path to invoke the script)
- Run this command to convert all the strokes (Refer the documentation for more help)
$ ./svg-stroke-to-path all myFile.svg
And also exported SVG from figma was very small (16x19) and I did use the Scale option in the Sketch to have the desired size of 200x200.