Custom template results in unknown substitution #856
Replies: 1 comment
-
Some workaround to it? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hey, I try to generate svg icons with svgr cli and used a custom template. I'm not able to get it to run and get an
Unknown substitution "$0" given
.command I'm using:
npx @svgr/cli --typescript --template src/components/icon/template.cjs --jsx-runtime automatic --filename-case kebab --out-dir src/components/icons -- src/components/icon/svg
Template:
I would expect that I can combine interface ${componentName}Props. I would like to add a custom interface to pass some props to the component. I also read in older issues/discussion that I should use something like tpl.smart(...typescript) but can't read anything about it in the readme. Someone knows a way how I can get it to work?
Beta Was this translation helpful? Give feedback.
All reactions