Replies: 21 comments 3 replies
-
preactjs/preact#3327 has been published in 10.6.0, we can also merge in the |
Beta Was this translation helpful? Give feedback.
-
I'm very excited about Preact support for Remix. What can I do to help? |
Beta Was this translation helpful? Give feedback.
-
Hey @pspeter3 it should work as of now, the only thing we need to do different is the const documentElement = document.documentElement;
const apply = n => document.replaceChild(n, documentElement);
hydrate(x, {
childNodes: [documentElement],
firstChild: documentElement,
insertBefore: apply,
appendChild: apply
} This because of our algo getting a bit confused 😅 we're hoping to land a fix but looking into the best way currently |
Beta Was this translation helpful? Give feedback.
-
Thanks! Is preactjs/preact#3328 the right issue to follow from the Preact side? |
Beta Was this translation helpful? Give feedback.
-
Well that was an initial solution but we're trying to find a smaller (and maybe in core) one |
Beta Was this translation helpful? Give feedback.
-
Is there an example repo with this work around used? Preact is awesome :D
|
Beta Was this translation helpful? Give feedback.
-
After some hours of implementing Preact in Remix, I finally found how annoying not having access to the Bundler API can be. And even after patching Remix compiler.js file, it still didn't work because of compatibility between Preact 8 and Preact X, and I didn't manage to make Preact X work with ESBuild. It would be cool if Jovi guided us in the correct direction on implementing it in Remix, as Preact is a key factor in performance optimization. |
Beta Was this translation helpful? Give feedback.
-
I would love to help out but we're not going to work on supporting 8 😅 else we'd be working on three major versions at once, I'll try to contribute a working example in the coming week |
Beta Was this translation helpful? Give feedback.
-
@phiberber #1636 adds an example |
Beta Was this translation helpful? Give feedback.
-
Is there any update on this? The example PR was closed with the status "we are waiting to get this natively supported". |
Beta Was this translation helpful? Give feedback.
-
Haven't heard back about this 😅 |
Beta Was this translation helpful? Give feedback.
-
Jovi, should've waited for the official implementation before deleting the example branch, anyone can follow the commit steps though. It has been a couple months already, I'm not even sure if this is going to be released this year, and based on this issue's activity, seems like thete is little to none demand (compared to other issues). |
Beta Was this translation helpful? Give feedback.
-
I do know the Remix team really wants to make Remix front-end agnostic. Preact has always been at the top of their list. With summer vacations and the major update to React Router, I believe this work was put on hold. It should pick back up soon after the new "Remix" router lands (with the data API) and deferred support. |
Beta Was this translation helpful? Give feedback.
-
There's also the remix routers repository, where work is being done to port There was also a tweet from Ryan himself playing around with Preact & HTM. He's importing what is a pre-release of the remix-router package, so I would presume there's some work that was already done. |
Beta Was this translation helpful? Give feedback.
-
@LukasCornille I've done an initial pass of a Preact layer here: brophdawg11/remix-routers#19 |
Beta Was this translation helpful? Give feedback.
-
Example with Deno https://twitter.com/ebey_jacob/status/1567055958727340032 |
Beta Was this translation helpful? Give feedback.
-
What would it take to get official support at this point? |
Beta Was this translation helpful? Give feedback.
-
😂 So many emoji reactions yet only 7 upvotes. Remember the upvote (↑) is all that counts towards raising visibility on the roadmap so don't forget to upvote it if this is something you'd like to see worked on! |
Beta Was this translation helpful? Give feedback.
-
As @ryanflorence pointed out in #7823, Remix is dedicated to be a React framework and not support other renderers |
Beta Was this translation helpful? Give feedback.
-
@developit Is there anything actually blocking official support for Preact at this point? It looks streaming SSR was added to Preact. I get that Preact support isn't a priority for the core Remix team at the moment, but if someone were to raise a PR, does anyone have a sense of if it would be accepted? |
Beta Was this translation helpful? Give feedback.
-
Preact Support
<Scripts>
diffing on the client (change in Remix)Make <Scripts> render nothing on the client #390wip: attempt at preact hydration support #403<!DOCTYPE>
hydration skipping to Preact 10 (change in Preact)document.documentElement
replacement (change inpreact/compat
)Beta Was this translation helpful? Give feedback.
All reactions