-
Notifications
You must be signed in to change notification settings - Fork 38
Type error on empty record with fragments in automatic mode #703
Comments
I'll look into it |
Probably one need to add a type annotation just like in other cases : |
babel output I think it should be: React.jsx(React.jsxFragment, {}: props<_>) |
Or, in rescript-react // React.res
type fragmentProps<'children> = {children?: 'children} // ? optional then React.jsx(React.jsxFragment, {}) It works fine |
This looks cleaner. |
I'll make a PR soon. |
The one thing to check is, that when |
If I understand correctly, isn't it same to the uppercase and lowercase component too? <Z /> // jsx(Z.make, {})
<Z> ... </Z> // jsx(Z.make, {children: ...})
<div /> // jsx("div", {})
<div> ... </div> // jsx("div", {children: ... }) I think the current |
This:
produces:
which gives a type errow (without location information):
The text was updated successfully, but these errors were encountered: