Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

kebab-case SVG Properties on JSX should be transformed to camelCase (e.g. clip-path to clipPath) #181

Open
softmarshmallow opened this issue Sep 22, 2022 · 0 comments
Labels
good first issue Good for newcomers

Comments

@softmarshmallow
Copy link
Member

softmarshmallow commented Sep 22, 2022

Using the raw svg data in JSX (react) will throw below runtime warning.

Warning: Invalid DOM property `clip-path`. Did you mean `clipPath`?

If the svg is inlined, it is a good practice to alter the property names to react tolerant keywords.

TODO

  • Find a property name map (or hard code the logic?)
  • Should this be handled by CoLI module?
@softmarshmallow softmarshmallow added the good first issue Good for newcomers label Sep 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant