devcards

Devcards aims to provide a visual REPL experience for ClojureScript https://github.com/bhauman/devcards
spieden 2016-01-05T00:48:53.000194Z

think i figured out a good way to build devcards for re-frame components that doesn’t rely on global state if anyone’s interested

spieden 2016-01-05T00:49:38.000195Z

short version: push the subscriptions out of the component itself and pass in a fn to do dispatch with

bhauman 2016-01-05T16:45:30.000196Z

@peeja it seems like if you have a separate build for devcards and also put a cards.html into a resources directory that is only available at dev time you should be set

bhauman 2016-01-05T16:53:15.000197Z

@spieden: it would be good to have a devcards reference page for reframe. I haven't used it yet so I my look at it soon lots of folks are wondering about this.

1👍
peeja 2016-01-05T16:57:38.000198Z

@bhauman: Oh, yeah, that should work! I forget you can do that… :simple_smile:

nberger 2016-01-05T18:26:38.000199Z

What about rendering re-frame components in devcards with global state, and "real" dispatch and everything? It would be kind of an "integration" devcard. I know this is complicated with re-frame because of the state, handlers and subscriptoins all being global... But perhaps it could work if each devcard is actually rendered in an iframe? I think @pandeiro suggested this idea to me some time ago, and I don't see why it could not work... What do you think about it?