reagent

juhoteperi 2022-11-11T14:13:22.342649Z

I did start working on React 18 support on Reagent this week and I wrote a blog post about the work: https://www.metosin.fi/blog/reagent-towards-react-18/ https://github.com/reagent-project/reagent/compare/v1.1.1...master

3
👀 2
😍 2
🙌 1
Charles Comstock 2022-11-11T17:41:31.580409Z

Perhaps this has already been well discussed, but I'm curious if anyone has explored recreating the minimal DOM diffing engine that powers React and then creating a feature compatible version of Reagent using that engine instead of React. I haven't explored the space at all, but I have the impression that there is significant overlap between the features Reagent provides and what React provides itself. I assume this would remove any compatibility with existing React plugins, which may be a major problem for some folks, but I also suspect it would also simplify the resulting code and hopefully produce a smaller bundle? Just curious if anyone else has explored that space or had any other thoughts on it.

lispers-anonymous 2022-11-11T19:30:34.895699Z

Reagent works when react is swapped out with the much smaller preact library: https://preactjs.com/

lispers-anonymous 2022-11-11T19:32:51.256419Z

I made a reference project a while back that compared the resulting bundle sizes https://git.sr.ht/~dannyfreeman/preact-reagent-demo

lispers-anonymous 2022-11-11T19:34:22.354769Z

It’s not exactly removing duplicate features of the two (react/reagent), but does result in smaller bundles.

Charles Comstock 2022-11-11T19:35:16.163669Z

Neat, I think this is very close to what I was thinking of. I will have to explore both preact and your project

lispers-anonymous 2022-11-11T19:36:02.070919Z

This might be more on the line of what you originally asked too https://bitbucket.org/sonwh98/mr-clean/src/master/ but as far as I know never made it out of the proof of concept stage. Still a neat project to look at

Charles Comstock 2022-11-11T19:37:59.560459Z

Thank you, both of those give me something to explore and consider. I kind of assumed there was prior art there, but nice to see several approaches already exist

1
Lone Ranger 2022-11-11T22:06:26.713049Z

I've thought about it but it seems hard

Lone Ranger 2022-11-11T22:06:45.854699Z

Seems like a really useful algo to have in your back pocket tho

Lone Ranger 2022-11-11T22:07:11.629909Z

@dannyfreeman thanks for the suggestions... and the username lol

lispers-anonymous 2022-11-11T22:20:08.327739Z

Please do not steal it 🙂

Lone Ranger 2022-11-11T22:27:09.018559Z

Whoa, the project or the username? Dang my friend it sounds like you’ve had some bad experiences

lispers-anonymous 2022-11-11T22:27:31.940399Z

Just the username, do what you want with the project lol

Lone Ranger 2022-11-11T22:27:53.641589Z

I just meant “it gave me enjoyment seeing your username”, I’m sorry if I implied IP theft of your username 🤣

lispers-anonymous 2022-11-11T22:29:07.453519Z

No worries lmao. I’m going to have to get it trademarked!