Fork me on GitHub
#nbb
<
2022-08-13
>
alvinfrancis11:08:52

Is the entirety of the google closure library supposed to be available for use in nbb scripts?

borkdude11:08:19

@alvin.francis.dumalus Not all of it is exposed, but if you need something let me know. It's also possible to use the google closure library from npm directly

alvinfrancis11:08:40

That is awesome. Thanks! Was just poking around with what's nbb compatible in terms of cljs libraries and was encountering missing google closure namespaces.

borkdude11:08:19

We could add those, just let me know which ones

alvinfrancis11:08:34

In this specific case, I wanted to see if something as broad as re-frame could be pulled in. And got Could not find namespace: goog.async.nextTick . There might be more there. Will keep poking around.

borkdude11:08:38

@alvin.francis.dumalus I see! Where would you use re-frame in the context of an nbb "app" / "script"?

alvinfrancis11:08:36

Still toying around with some ideas, but stuff like https://github.com/eccentric-j/cljs-tui-template ported over to just a script seem pretty cool. Right now, I'm playing around with using kafkajs and rendering live output with ink . While really easy, the streaming nature of kafka here lends itself well to re-frame's events.

alvinfrancis11:08:17

Honestly, just having fun with it right now 😉 Not sure if it's something that does make pragmatic sense.

borkdude11:08:06

Yeah, makes sense. For now you could probably do it in the small with just a global reagent atom and functions bashing on that state

borkdude11:08:18

I'm open to adding re-frame if more people are interested in using it

borkdude11:08:53

The best way to "poll" this is to make a Github Discussion so people can provide feedback

alvinfrancis11:08:30

Sounds good :thumbsup: Although personally, I think probably better not to bundle it with nbb even if it's lazily loaded if that's what you mean by including it. Reagent is already plenty 🙂

borkdude11:08:31

alright then :)