ngneat / svg-icon

👻 A lightweight library that makes it easier to use SVG icons in your Angular Application
https://netbasal.com
MIT License
257 stars 35 forks source link

feature(svg-generator): Add config-dir option to svg-generator CLI #92

Closed qortex closed 2 years ago

qortex commented 2 years ago

svg-generator CLI now takes an optional argument to specify where the svgGenerator config object should be looked for, defaulting to previous behavior of looking in the current working directory.

This allows to support use cases where separate instances of svg-generator shoud be used in subdirectories of the target project (typically in a Nx monorepo setting).

Close #64

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

[ ] Bugfix
[x] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Other... Please describe:

What is the current behavior?

Issue Number: #64

What is the new behavior?

A custom config dir can be specified for svg-generator CLI.

Does this PR introduce a breaking change?

[ ] Yes
[x] No

Behaviour is unchanged when the new option is not used (defaults to current working directory, current behaviour).

Didn't see how to introduce an auto test for that, but it relies on the well-known commander package.

Other information