-
Notifications
You must be signed in to change notification settings - Fork 26
Open
Labels
Description
It's currently impossible to render a class from a ReactT. This should be possible with locally or something.
In the best of all worlds you could do something like:
div_ $ do
someClass
span_ "this is not a class"There are a few problems though...
someClassis notReactTso we can't use do notation here. Okay, we could useRebindableSyntaxto make this possible, but I think that's a bad idea. Instead, why not extendlocallyto take either aReactTor aReactClass.- The meaning of a class is not super clear. In the current formulation it's where state is stored in an
IORef, but that's an implementation detail, not a means of abstraction. Maybe we don't need classes. Maybe we can figure out a clearer meaning for them.createClassalso feels really weird. It's stateful in an unclear way and lives in the IO monad.