1.0.3-alpha.1 • Published 2 years ago

@empathyco/x-svg-converter v1.0.3-alpha.1

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
2 years ago

Convert SVGs into Vue components to use with the X Design System

This project generates Vue components from SVGs in a folder, with the format required for the XDS

How to use it

Params

It receives two parameters, the first one should be the path to the folder containing the SVGs. The second one indicates if the source SVG files should persist at the end of the process (--keep-svgs). By default, the SVGs are deleted.

  • sourcePath: path of the folder with the SVGs.
  • keepSVGs: indicates if the SVGs are preserved at the end. false by default.

Run it as script

Run the following command to generate a Vue component from each SVG in the source folder:

ts-node ./src/svg-to-vue.ts ./yourSourceFolder

If you want to keep the source SVGs, add the --keep-svgs param:

ts-node ./src/svg-to-vue.ts ./yourSourceFolder --keep-svgs
1.0.3-alpha.1

2 years ago

1.0.2

2 years ago

1.0.0

2 years ago

1.0.1-alpha.0

2 years ago

1.0.0-alpha.10

2 years ago

1.0.3-alpha.0

2 years ago

1.0.2-alpha.0

2 years ago

1.0.0-alpha.9

2 years ago

1.0.0-alpha.8

2 years ago

1.0.0-alpha.7

2 years ago

1.0.0-alpha.6

2 years ago

1.0.0-alpha.5

2 years ago

1.0.0-alpha.4

2 years ago

1.0.0-alpha.3

2 years ago