What does HackerNews think of starboard-notebook?
In-browser literate notebooks
What I don't like it is that they invented yet another markdown syntax for code cells - it is the opening bracket # %[python] with no closing bracket.
There already is a popular markdown code cell syntax of [2]
```python
```
There's Starboard (which I'm building, it's built specifically for the browser and can integrate into a larger app deeply) and JupyterLite (the closest you will get to JupyterLab in the browser), either can be a good choice depending on your requirements. Both use Pyodide for the Python runtime.
[1]: https://github.com/gzuidhof/starboard-notebook, demo: https://starboard.gg
Outside of that use-case, I think notebooks are great for the first 20% of the effort that gets 80% of the work done. If it turns out one also needs to do the other 80% of the effort to get the last 20%, it is time to "graduate" away from a notebook. For instance if I am participating in a Kaggle machine learning competition I may train my first models in a Jupyter notebook for quick iteration on ideas, but when I settle onto a more rigid pipeline and infra, I will move to plain Python files that I can test and collaborate on.
This "graduation" from notebook to the "production/serious" environment should be straightforward, which means there shouldn't be too much magic in the notebook without me opting into it. Documentation in my eyes is not so different, I should be able to copy the examples easily into my JS project without knowing specifics of Observable and adapt it to my problem. Saying "don't be lazy and just learn Observable", or "you must learn D3 itself properly to be able to use it anyway" is not helpful. Observable being a closed, walled garden doesn't help: not being able to author notebooks without using their closed source editor is a liability that I can totally understand makes it a non-starter for some companies and individuals.
I think it's ok to plug my own project: It's called Starboard [1] and is truly open source [2]. It's built on different principles: it's hackable, extendable, embeddable, shareable, and easy to check into git (i.e. I try to take what makes the web so great and put that in a notebook environment). You write vanilla JS/ES/Python/HTML/CSS, but you can also import your own more advanced cell types. Here's an example which actually introduces an Observable cell type [3] which is built upon the Observable runtime (which is open source) and an unofficial compiler package [4]. I would be happy for the D3 examples to be expressed in these really-close-to-vanilla JS notebooks, but I doubt I can convince the maintainers to do so.
[1]: https://starboard.gg
[2]: https://github.com/gzuidhof/starboard-notebook
[3]: https://starboard.gg/gz/open-source-observablehq-nfwK2VA
[4]: https://github.com/asg017/unofficial-observablehq-compiler
If you're looking for next steps: You can actually run user code using `import`, which will allow your users to import code from external websites using familiar `import {x} from "https://some-url.com/bla.js"` syntax at the top of cells. Here's how:
const exportsInCell = await import(URL.createObjectURL(new Blob([USER_CODE], { type: "text/javascript" })));
And with some transpilation you can support top-level await in eval [1]. Just some pointers![0]: https://starboard.gg & https://github.com/gzuidhof/starboard-notebook
[1]: https://github.com/gzuidhof/starboard-notebook/blob/master/s...
A sibling comment introduces JupyterLite and Brython, which are Jupyter-but-in-the-browser, whereas with Starboard I'm trying to create what Jupyter would have been if it were designed for the browser first.
As it's all static and in-browser, you can embed a notebook (or multiple) in a blog post, for instance to power interactive examples. The bundle size is a lot smaller than JupyerLite for the initial load - it's more geared towards fitting into existing websites than being a complete IDE like JupyterLab.
* https://pyodide.org/en/latest/
Think Jupyter Notebook but built for the web.
[0]: https://starboard.gg [1]: https://github.com/gzuidhof/starboard-notebook
Here's an example notebook that shows p5.js use (with Python interop as a bonus): https://starboard.gg/nb/n3DYopT
It supports local or self-hosted editing and viewing [1] and is all open source.
[0]: https://starboard.gg [1]: https://github.com/gzuidhof/starboard-notebook and https://github.com/gzuidhof/starboard-cli
I'm building something similar called Starboard Notebook[0] that has a different set of trade-offs. It ends up being something in between Jupyter and Observable:
* One of the goals is to build Jupyter how it would have been if it was designed for the web (only).
* It's open source [1], plays nice with git (the format is plaintext), and supports local viewing & editing [2]
* Because of that you can host it yourself, put it on your blog / github pages, anywhere.
* There is little magic, it actually is just Javascript at it's base. This means you can use standard browser APIs and HTML, and when you are ready to "graduate" the notebook implementation that should be straightforward. In my eyes notebooks are only for the first 20% of the work that does 80% of the job for small applications/experimentation (which is often where it ends anyway).
* You can "build the ship as you sail": you can load new cell types dynamically at runtime. This is also how Python is supported (through WebAssembly).
* You can have interop with Python and Javascript which is really powerful. Example: Create a drag an drop form using HTML+JS, then process the dropped CSV file using Pandas and visualize using matplotlib.
[0]: https://starboard.gg [1]: https://github.com/gzuidhof/starboard-notebook [2]: https://github.com/gzuidhof/starboard-cli
I feel like I must be missing something here; you want to aggregate your syslog data; you have a bunch of files and a web browser.
Now what?
You beat your keyboard against the monitor while your browser sandbox steadfastly refuses to load your local file system files? [1]
You write your own server that serves data and the open source core? [2]
Yay, you now have the dubious honour of having re-invented jupyter notebooks, only, you had to roll it yourself, and it's insecure and really not very good compared to an existing mature product.
What can you actually do with this, that you can't do by right clicking on your browser window and picking 'inspect', and then clicking on 'console'?
You can certainly make interactive blog posts; absolutely, I 100% acknowledge that as a blog plugin, when you have already got a server to host your content, this would be pretty awesome.
If you do want to run your own databricks / notebook SAS, then I also see it as being a really great kickstart for you, absolutely.
However, out of the box? I'm... like, I think this is interesting, but I don't see how I could actually use it.
[1] - https://stackoverflow.com/questions/50007055/fetch-request-t...
Cell-by-cell notebooks like Jupyter are great for prototyping, explaining and exploration, but their dependence on a Python server (with often undocumented dependencies) limits their ability to be shared and remixed. Now that browsers support dynamic imports, it has become possible to create a similar workflow entirely in the browser.
That motivated me to build Starboard Notebook, a tool I wished existed. It's:
* Run entirely in the browser, there is no server or setup, it's all static files.
* Web-native, so no widget system is necessary. There is nearly no magic, it's all web tech (HTML, CSS, JS).
* Stores as a plaintext file, it will play nicely with version control systems.
* Hackable: the sandbox that your code gets run in contains the editor itself, so you can metaprogram the editor itself (e.g. adding support for other languages such as Python through WASM).
* Open source (https://github.com/gzuidhof/starboard-notebook).
You can import any code that targets the browser directly (e.g. puts stuff on the window object), or that has exports in ES module format.
I'm happy to answer any questions!