Is anyone developing a SPA package like R/Shiny or Python/Dash?

Thanks for the feedback and the great ideas!

1/ I agree with what was said about writing pseudo HTML in Julia - I strongly dislike it (re @dfdx). It’s a nightmare in terms of editor support and it forces expensive back-end developers to write trivial view code that should be the job of junior web devs. It’s also not nice when what should be HTML and generate at most a warning in the browser, can generate fatal Julia errors crashing the whole app.

2/ Exactly, the code does not have to be all in Julia. On the contrary, talking about Genie at least, it is a MVC framework and I’d like the view code to stay in the view (@djsegal)

3/ Despite all the hype surrounding WebAssembly, my research made me believe it’s not ready for general production use yet. Every few months I check developments and there was not a single professional/expensive/high profile product built with it yet. (@Palli)

These reasons and a few more make me believe Predix is the best choice so far (at least as a UI toolkit for Genie). Take for example the code for rendering a Data Table component with Predix.

<px-data-table
table-data='[{"first":"Valentine","last":"Meyer","email":"valentinemeyer@scentric.com"},{"first":"Silva","last":"Alexander","email":"silvaalexander@gmail.com"},{"first":"Hopkins","last":"Wong","email":"hopkinswong@hotmail.com"},{"first":"Joe","last":"Sherman","email":"joejoe@yahoo.com"},{"first":"Jane","last":"Bartlett","email":"jane@scentric.com"}]'
language="en">
<px-data-table-column
name='first'>
</px-data-table-column>
</px-data-table>

You can check it here, it’s pretty: Predix UI – Learn From Scratch

It is “plain” HTML. Which means it fits nicely in the view layer. This in turn means proper editing tools (for HTML plus Polymer), separation of concerns, an efficient workflow for larger teams (designers edit the views, developers the models and the controllers). And it also means no parsing and evaling Julia, instead being able to use Genie’s compiled views or just pure HTML. (Of course, there is the issue of client side rendering with Polymer, but no JS framework is above client side rendering).

Equally important, the only dynamic part would have to be the JSON data within table-data so on the Julia side of things all we’d have to do is setup the corresponding Dict() and have the framework take care of sending it down the pipe.

My vision is also that at some point we’ll also have a visual builder so that writing Dicts and view files by hand won’t be necessary for simple apps. Just drag-drop the component, use a UI to configure it, bind it to a data source and it’s done! Think Microsoft’s Visual Studio.

This architecture is probably not the right fit for all the stacks that were mentioned in this thread, but it does fit beautifully in the Genie narrative.

2 Likes