nosco / hx

A simple, easy to use library for React development in ClojureScript.
MIT License
247 stars 16 forks source link

React Hooks helpers #4

Closed lilactown closed 5 years ago

lilactown commented 5 years ago

Based on current React RFC https://github.com/reactjs/rfcs/pull/68

pepe commented 5 years ago

I am actually pretty eager of what this bring to the table in the state management story.

Again, I very much like the hx approach.

pepe commented 5 years ago

This is good. I thought I have seen some examples of usage, but cannot find them anwhere, is it true?

Also are you OK if I create Issue for something like cursor curson-in from tonsky/rum?

lilactown commented 5 years ago

I'm going to work on updating the examples to use hooks instead of (or at least along side) react classes. I did an initial POC of some hooks helpers in this repo: https://github.com/Lokeh/hooks-demo

I'm not super familiar with rum's cursor implementation but sure, go ahead. IMHO atomic cursors should be their own library; but implementing it in hx might be the only tenable to do it performantly (a la reagent)... yes create an issue :P

pepe commented 5 years ago

Great. Thank you very much!

pepe commented 5 years ago

And yes hooks-demo was the place I have seen it. Thanks!