Yes, that works when you have a compilation step on the server.
But it would be nicer to have a complete project in the browser.
Think of it this way: When someone hits 'export' and downloads the zip - how will they be able to run what they built? They need to set up a whole serverside toolchain. If you instead load vue clientside, the downloaded thing would work right away. Without any setup or dependencies.
This applies to the React example just as well.
The server side toolchain is how most devs do it these days. I personally prefer to skip it.
Demoboard is really made for throwing together a demo as quick as possible. But I think https://codesandbox.io would suit what you want perfectly. Have you given it a try?
Demoboard would work just as well. It's just about how you set up the examples. One moment ... let me make an example without a server side toolchain involved ...
Yeah, I really do like this way of doing it. I might change the Vue example to do that. For React though, the HTML is usually empty, so it ends up hiding the dependencies within a tab that nobody looks at, so imports are a lot clearer.
Perhaps I could find a way to transform imports into script statements in the exported file. I'll have a think about it...
Perhaps I could find a way to transform
imports into script statements in the exported file
Uhh no! That would be even more hidden magic. The beauty of your platform really shines when there is no hidden process. When the user can transparently see what happens.
There really is no difference between Vue and React in this regard. The React demo without a server side toolchain looks like this:
Packing up the imports into (a) boilerplate html and (b) boilerplate package.json would allow people to code stuff up quickly in your editor and then download it for integration in their own pipelines with minimal hassle (Maybe add buttons to download as zip with dependencies either in index.html or in packages.json?)
But it would be nicer to have a complete project in the browser.
Think of it this way: When someone hits 'export' and downloads the zip - how will they be able to run what they built? They need to set up a whole serverside toolchain. If you instead load vue clientside, the downloaded thing would work right away. Without any setup or dependencies.
This applies to the React example just as well.
The server side toolchain is how most devs do it these days. I personally prefer to skip it.