Live data from Hacker News

Reactive Clojure: A web language

hyperfiddle.notion.site

161–170 of 185 posts

Re: Reactive Clojure: A web language

#161

Earlier quoted context omitted.

As opposed to actually spending their time building useful practical things?

I hope you don't live every second of your life building useful practical things.

I do actually. What else are you supposed to do with your time? Life is short, best to use it.

Re: Reactive Clojure: A web language

#162
post #159

Earlier quoted context omitted.

Mr first thought reading the article was security. After a quick ctrl-f, it was a little disconcerting to find that the only mention of security is in a tacked-on bullet list under the heading "risks"...

why is this any different from any other web api security concerns?

When I edit Clojure I only ever think about indentation: https://shaunlebron.github.io/parinfer/

Re: Reactive Clojure: A web language

#163
post #116

Earlier quoted context omitted.

After a naive removal of the tests (every folder and files that contains tests was deleted), React still has 190k lines of code. > React has one job, and it does it really well I'm not sure I agree. It's hard to compare without a minimal copy of React to see how small it can get, but I'm guessing it could be an order of magnitude smaller. For example, React supports different ways of doing things (class components, f…

I’m going to keep scrolling in search of a shorter comment

Why?

Re: Reactive Clojure: A web language

#164
post #116

Earlier quoted context omitted.

LoC != Complexity. React has one job, and it does it really well, part of that 350k lines of code is a LOT of tests. Just because it has those tests doesn’t mean it’s “much more complex”. My two cents :)

After a naive removal of the tests (every folder and files that contains tests was deleted), React still has 190k lines of code. > React has one job, and it does it really well I'm not sure I agree. It's hard to compare without a minimal copy of React to see how small it can get, but I'm guessing it could be an order of magnitude smaller. For example, React supports different ways of doing things (class components, f…

Preact is React without the fluff - https://github.com/preactjs/preact

loc in a node project is hard to judge due to packages and the aforementioned mono repo difference, but the preact functional build artefact is an order of magnitude smaller: 129KiB v 8.2KiB

Re: Reactive Clojure: A web language

#165
post #39

This reminds me of Meteor.js[0] from back in the day (2014?), which had a very similar approach—you wrote code that ran on both the frontend and the backend, and database updates were propagated automatically. It suffered from a pretty hard reliance on Mongodb and its own package manager (Atmosphere), and it was at odds with the rest of the JS ecosystem which was settling on NPM. This project looks very cool! I like…

I feel like Meteor lost a lot of ground to Firebase. I think what we are seeing with these tools to make data synchronization in the frontend more invisible will continue to proliferate. I am looking forward to the next, rich landscape of interactivity on the web powered by WASM, WebGL, etc.

i think you mean WebGPU rather than WebGL. also WebTransport will play a big part for truly real-time interactive web apps

Re: Reactive Clojure: A web language

#166
post #140
post #100

Earlier quoted context omitted.

It's a very impressive project, and something I would definitely try in a greenfield app. I wish there was somewhere to follow updates that wasn't Twitter though.

Especially for people without Twitter accounts

Try this https://fraidyc.at/

Re: Reactive Clojure: A web language

#167
post #75

Earlier quoted context omitted.

The problem with this type of system in my experience is that it’s great until you hit a bug, and then you realize you have no idea what’s going on under all the automagical stuff and you go crazy

That's true with any system you haven't sufficiently studied.

So yes in a way, but here we're talking about something that synchronises state between a client and DB over http. The possibilities of weird edge cases seem endless :)

Re: Reactive Clojure: A web language

#168
post #49

Finally the problem which PHP solved more than two decades ago has been solved again. How do we include server-side code in client-side code? Do we build the client-side on the sever, and render? Why no, that would be PHP. Let's build the client-side in the browser, and rig a series of complex code-generating primitives disguised by the beauty of a language, to AJAX our way to a presumably good-enough solution. I thi…

PHP doesn't reactively and selectively propagate changes between client and server, nor would it be feasible to write such a library in PHP itself. You could maybe achieve something similar with code generation of PHP and JS.

You can use SSE with PHP to propagate changes.

Re: Reactive Clojure: A web language

#169

Interesting how no one has mentioned Fulcro. There seems to be a lot of overlap between the two. Anyone who has used both and mind comparing them? https://fulcro.fulcrologic.com/

Yeah Fulcro has been building up their implementation of these ideas for ages, and used in anger, I think most famously by nubank. From https://book.fulcrologic.com : "The core ideas are as follows: Graphs and Graph Queries are a great way to generalize data models. UI trees are directed graphs that can easily be "fed" from graph queries. User-driven operations are modeled as transactions whose values are simply data…

Am I wrong or is fulcro frontend only though? You wouldn’t get access to any server resources so you still need to manage syncing state with the server. Or am I wrong about that?

Re: Reactive Clojure: A web language

#170

Earlier quoted context omitted.

Yeah Fulcro has been building up their implementation of these ideas for ages, and used in anger, I think most famously by nubank. From https://book.fulcrologic.com : "The core ideas are as follows: Graphs and Graph Queries are a great way to generalize data models. UI trees are directed graphs that can easily be "fed" from graph queries. User-driven operations are modeled as transactions whose values are simply data…

Am I wrong or is fulcro frontend only though? You wouldn’t get access to any server resources so you still need to manage syncing state with the server. Or am I wrong about that?

Yeah you were mistaken, it's a full stack design. They recommend https://github.com/wilkerlucio/pathom for the connection. It's GraphQL done right, you write data "resolvers" on the backend, you declare very flexible graph queries on the front end -> this populates client DB and then fulcro uses that to render frontend.

Highly recommend reading through this section: https://book.fulcrologic.com/#FullStack

Post reply on HN