5 ms·
Does anyone know if React will be able to interop with this? Certainly there are solutions to letting a React component re-render based on its own width, even a
by btown 5y ago
Does anyone know if React will be able to interop with this? Certainly there are solutions to letting a React component re-render based on its own width, even as that might change over time. But I imagine there would be performance improvements to let CSS container queries handle all styling for a component, rather than needing to go back into JS land every time. And because said CSS would be scoped, it would make CSS-in-JS possible without needing to add auto-generated prefixes etc. You'd perhaps need your React component (not each component instance) to maintain a template for itself, which might be tricky.
- muspimerol 5y agoWhy would you want React interop for the styling? What would that even mean? Struggling to understand the use case here.
- eyelidlessness 5y agoIf I remember correctly, React web component support is limited. But Preact explicitly supports them, as well as many other JSX libraries.