Software Engineer ⚡️ Crafting some of the most popular Tailwind CSS plugins around. Bugs are my own. Dev-tooling & spec-reading fanatic 💻 #codeinpublic
Promoting free speech would mean promoting open debate. This is exactly the opposite.
Promoting free speech would mean promoting open debate. This is exactly the opposite.
if free speech died, it happened long before now
if free speech died, it happened long before now
I really appreciate you maintaining such a great plugin. I know a lot of work goes into that. I'm happy to compensate you for any time spent on this if you like.
I really appreciate you maintaining such a great plugin. I know a lot of work goes into that. I'm happy to compensate you for any time spent on this if you like.
Still, how would you avoid useEffect here, if you would? I'm waiting until the session is ready to know if the user is logged in or not.
Still, how would you avoid useEffect here, if you would? I'm waiting until the session is ready to know if the user is logged in or not.
I generally advocate for separating concerns and moving complex logic into new components, but I often have to do this for a simple conditional and nested pieces of composition simply to hold state.
I’d love nesting!
Thanks again!
I generally advocate for separating concerns and moving complex logic into new components, but I often have to do this for a simple conditional and nested pieces of composition simply to hold state.
I’d love nesting!
Thanks again!
This approach seems to have the fewest gotchas and simplifies the syntax, making it feel more native.
My biggest hesitation with this approach is that I believe in “Just JavaScript,” and while this would be JS, it feels more magical since it happens outside of React.
This approach seems to have the fewest gotchas and simplifies the syntax, making it feel more native.
My biggest hesitation with this approach is that I believe in “Just JavaScript,” and while this would be JS, it feels more magical since it happens outside of React.
Immediately, I could replace that <$> wrapper with a familiar-feeling string directive, like 'use render' (or similar).
Any block using that directive would immediately be broken out into a separate component.
Immediately, I could replace that <$> wrapper with a familiar-feeling string directive, like 'use render' (or similar).
Any block using that directive would immediately be broken out into a separate component.
Something great about this approach is that as long as the pre-compilation is robust and works effectively, I could simplify the syntax even further.
Right away, we remove the need to use a callback; we can simply match any content wrapped in syntax like <$> and expand that.
Something great about this approach is that as long as the pre-compilation is robust and works effectively, I could simplify the syntax even further.
Right away, we remove the need to use a callback; we can simply match any content wrapped in syntax like <$> and expand that.
e.g. Vite/Webpack/etc.
In this approach, I would pre-compile any uses of this <$> syntax and *actually* break its usage out into separate functional components within the same file.
Natural hoisting makes this even easier because we don’t have to worry about order.
e.g. Vite/Webpack/etc.
In this approach, I would pre-compile any uses of this <$> syntax and *actually* break its usage out into separate functional components within the same file.
Natural hoisting makes this even easier because we don’t have to worry about order.
With the proxies approach, instead of passing the hooks themselves to the callback, I would pass a proxy that watches how the hook is used and somehow carries that usage back to the component instance itself, outside the callback.
I’m not sure how difficult (or possible) that is.
With the proxies approach, instead of passing the hooks themselves to the callback, I would pass a proxy that watches how the hook is used and somehow carries that usage back to the component instance itself, outside the callback.
I’m not sure how difficult (or possible) that is.
I have two defining ideas—
– proxies
– build plugin
I have two defining ideas—
– proxies
– build plugin
My primary objective here was to tackle this problem with an approach that ensures the hooks are initialized and used in the same render cycle, which they appear to be, but I can see how it might still violate the rules.
My primary objective here was to tackle this problem with an approach that ensures the hooks are initialized and used in the same render cycle, which they appear to be, but I can see how it might still violate the rules.
Thinking through my implementation, it does feel like a pattern that React Compiler could officially support with the proper affordances.
Thinking through my implementation, it does feel like a pattern that React Compiler could officially support with the proper affordances.
Do you happen to have a concrete example you could share that I could test around for where this would likely break?
My implementation is different than the usual `children()` approach, but I’m sure it hits the same limitations.
Do you happen to have a concrete example you could share that I could test around for where this would likely break?
My implementation is different than the usual `children()` approach, but I’m sure it hits the same limitations.
TY 🙏🏼
TY 🙏🏼
x.com/en_js/status...
The conversation has progressed past that point into a few tangential conversations and DMs, but I think addressing and discussing the concern there would be fitting, both for my package and that article I shared^
x.com/en_js/status...
The conversation has progressed past that point into a few tangential conversations and DMs, but I think addressing and discussing the concern there would be fitting, both for my package and that article I shared^