Closed dddlr closed 7 months ago
Latest commit: b6f22b39081b6facdc67797ca842ab6bf7a18466
The changes in this PR will be included in the next version bump.
Not sure what this means? Click here to learn what changesets are.
Click here if you're a maintainer who wants to add another changeset to this PR
For some reason, if you passed
props => ...
directly tostyled.div
orcss()
, and the return value of the arrow function was an object, you would cause@compiled/babel-plugin
to crash:On the other hand, wrapping the return value inside a logical expression or ternary expression would make it work perfectly fine:
(note the above examples exclude TypeScript type annotations for simplicity)
This PR fixes this discrepancy.
Todo