You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In summary, if you use @twind/wmr and import preact/compat, re-render is broken by the error Cannot set property className of #<Object> which has only a getter
Although I haven't investigated why preact/compat causes this issue, the error itself is caused because the component having tw has className getter when re-render.
When I manually deleted the getter by debugger, the second time rendering succeeded. So, I guess we can implement that logic in @twind/preact regardless of the issue caused by preact/compat.
The text was updated successfully, but these errors were encountered:
See https://codesandbox.io/s/rrjq1?file=/public/index.js
In summary, if you use
@twind/wmr
and importpreact/compat
, re-render is broken by the errorCannot set property className of #<Object> which has only a getter
Although I haven't investigated why
preact/compat
causes this issue, the error itself is caused because the component havingtw
hasclassName
getter when re-render.First time rendering
Second time rendering
When I manually deleted the getter by debugger, the second time rendering succeeded. So, I guess we can implement that logic in
@twind/preact
regardless of the issue caused bypreact/compat
.The text was updated successfully, but these errors were encountered: