svg-to-tsx
v0.1.0
Published
Convert all your SVGs to a single TSX module
Downloads
27
Readme
svg-to-tsx
Convert all your SVGs to a single TSX module
Usage
- Run
npm i svg-to-tsx
- Add following script to your
package.json
"icons": "svg-to-tsx -i ./input/path -o ./output/path -n fileName"
- Run
npm run icons
CLI Options
| Short | Long | Description | Default | | ----- | -------- | ----------------------------------- | ------- | | -i | --input | Path to where SVG files are located | none | | -o | --output | Output module destination path | none | | -n | --name | Output module file name | "icons" |
Warning
This package was made in a hurry because I needed it for my website. I will improve it somewhere in the future with additional settings.