-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
idyll like api #121
Comments
There are so many interesting APIs out there 🤯 The benefit they have that we don't is that nbKarax doesn't allow communication between nbKarax-blocks. So we wouldn't be able to do the example they have like this: nbGraph()...
nbButton()
nbButton() where each call calls nbKarax. We would need to combine them into a single nbKarax block for it to work. 🤔 Unless you have a brilliant idea to drag out from your magic hat as usual 🧙♂️🃏 Another idea would be that each component adds a VNode to a list which Karax then loops over. We can't complain about not having any ideas for new themes and APIs at least 🤣 |
yes, I think the simplest would be to implement it as a single block like: nbIdyll: #adds template for all the apis
text "..."
input
button
... and then probably it is possible in some way to split it (as you mention, every piece would need to add procs and VNodes to a list and you could have a
Not really. It think the interest here is if we can reuse the stuff that is in idyll repo. (plus they do have a nice gallery)
I do have a private repo with a list of ideas (issues) on things to do with nim (not all of them apply to nimib), so... not running out so soon. Especially with the pace I have implementing them... 🤣 |
Yes that sounds like the best idea 👍
Procs will be troublesome because you can't serialize a proc so you can't send it from C -> JS sadly. VNodes I'm not certain of but it might also be troublesome if it holds any references 🤔 So we will basically have to do everything on the javascript side. But maybe that's what you meant. I'm leaning a bit towards some kind of macro which just copy-pastes code blocks into a
Oh, I misread your first post as reusing the work that we did on components 🤦 Yes le's hope what they did can be done similarly here. And they did have a very nice gallery indeed.
Look at that, I'm only seeing the top of the iceberg of ideas 🤣 |
now that we have nbKarax, I think it would be a nice project to try and build a idyll like api (which is based on react): https://idyll-lang.org/docs
hopefully we can reuse the work they did on components.
The text was updated successfully, but these errors were encountered: