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
[Box] Test props to attributes forwarding #15365
Conversation
It's a bug. |
No bundle size changes comparing db67bf2...5f13632 |
Turns out I was running the wrong test suite. |
@eps1lon It's just a bug in styled-components then? |
I mean not really. Why should We should probably show in the examples how this could be avoided. |
They do it to ease the DX. It's arbitrary, they are using an emotion package actually. |
Since this issue is still open I don't think this is expected behavior. Sounds like they do forward everything. |
@eps1lon Should we close the pull request? |
I would keep it as a regression test. I'd have to dig more into |
@eps1lon The problem impacts styled-system too https://codesandbox.io/s/kxwwqkrkmv. I'm not aware of any alternative than to write a custom filter logic like we do in Material-UI/Box. |
Well then even better we put a test for this behavior in place. Sounds like this was deliberately implemented but not actually tested. |
* [Box] Test props to attributes forwarding * correct tests
This currently creates invalid HTML. Not sure if desired or not but the behavior should be documented in some form (e.g. a test).Box
does not forward the props as DOM attributes.