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 the minimal repro, no CSS is generated for the nested component with the tailwind class
This can be fixed by removing the line in @twind/core/core.js
functionmo(tw){letobserver=newMutationObserver(handleMutationRecords);return{observe(target){observer.observe(target,{attributeFilter: ['class'],subtree: true,childList: true});/** DELETE THESE COMMENTED CODES * // handle class attribute on target * handleClassAttributeChange(target); * // handle children of target * handleMutationRecords([ * { * target, * type: '' * } * ]); */},disconnect(){observer.disconnect();}};functionhandleMutationRecords(records){for(let{ type , target }ofrecords)if('a'==type[0])/* attribute */// class attribute has been changedhandleClassAttributeChange(target);
...
I don't know what the deleted code is for. According to the @twind/with-web-components, the target should be a shadowRoot, but these two functions should perform attribute on a Element
Reproduction
https://github.com/uihp/mcve-twind-nested-components
Describe the bug
In the minimal repro, no CSS is generated for the nested component with the tailwind class
This can be fixed by removing the line in
@twind/core/core.js
I don't know what the deleted code is for. According to the
@twind/with-web-components
, thetarget
should be a shadowRoot, but these two functions should perform attribute on a ElementSeverity
annoyance
System Info
Additional Information
No response
The text was updated successfully, but these errors were encountered: