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

[Bug]: Iconbase does not pass children prop despite accepting one #814

Open
jasperfirecai2 opened this issue Sep 13, 2023 · 2 comments
Open
Labels

Comments

@jasperfirecai2
Copy link
Contributor

jasperfirecai2 commented Sep 13, 2023

Describe the bug

IconBaseProps accepts the children prop meaning JSX like

<FaApple>
<span>Hello world</span>
</FaApple>

would be valid. However, the children will not be displayed.

Expected behavior

Either props.children should be rendered as a child, or the component should not accept children as a prop.

Minimal sample repository URL

https://gist.github.com/jasperfirecai2/8a7171243f61067e94fa7c40f7ac1ce3

Steps To Reproduce

  1. Add children to a react-icons icon node
  2. Render your component
  3. Children will not be rendered

Package version

4.11.0

Relevant log output

No response

Additional context

Allowing children to be rendered would allow license attribution to be added to icons in jsx code.

@hustlerZzZ
Copy link

Hi, I can fix this issue can you please assign this to me?
Thanks

@AdiMarianMutu
Copy link

Will this be addressed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants