Live data from Hacker News

Elixir Livebook is a secret weapon for documentation

fly.io

41–50 of 72 posts

Re: Elixir Livebook is a secret weapon for documentation

#41

Earlier quoted context omitted.

Jupyter outputs to JSON. Livebook outputs to markdown, so it's more naturally renderable outside of the tool itself. There are still some rough edges -- it would be nice if livebook could cache prerendered content. for example, kino graphs only chuck a big fat JSON into a html comment, it would be nice if it also popped out an svg or encoded png with data uri.

I believe you can hover the corner of a graph and hit the (...) disclosure for a "save svg" button.

Well it should be automatic and it should inline it.

Re: Elixir Livebook is a secret weapon for documentation

#42

I would suggest to anyone to download Livebook and test it out, even if you don't know Elixir or Erlang. You can do so much with it. I even use it for things outside of programming due to it being pretty much a markdown notebook that you can run code inside of. It's one of my favorite tools.

For linux the easiest way to download livebook is with docker [1] or maybe with fly.io [2].

Installing it directly is a bit complicated if you are not familiar with it. I wish linux also had Desktop app like mac.

[1]: https://github.com/livebook-dev/livebook#docker

[2]: https://fly.io/launch/livebook

Re: Elixir Livebook is a secret weapon for documentation

#44

One simple thing I need thats stopping me from jumping into Livebook fully: Salesforce API integration. Right now, I can't manage to make the auth work there (since oAuth needs some http redirect dance). Connecting to some proper SQL database is a breeze, but if I cannot access some silo'ed data that is absilute critical, its not that useful after all :-/

Please open up a discussion on Livebook repo? We would love to understand more what is missing here. :)

The OAuth2 authorization code workflow involves a redirect step.

Re: Elixir Livebook is a secret weapon for documentation

#45

Sorry for asking a dumb question, but how is this different from using Jupyter to write your interactive documentation/runbooks and interactive tests?

While Livebook will mostly have an appeal for people already working with erlang/elixir, it does have a few features that are pretty nice.

- it’s collaborative (think Google docs for code) when several people are working on the same instance of a livebook;

- it’s easy to extend with so-called smart cells (which are essentially pieces of gui you can inject in your document https://news.livebook.dev/v0.6-automate-and-learn-with-smart... ). Smart cells are available for various tasks (db connection/ interaction, data frame exploration, ML tasks, maps), and building your own is relatively easy;

- you can turn a notebook into a web app ( https://news.livebook.dev/deploy-notebooks-as-apps-quality-o... )

- you can run your code an a remote elixir node by attaching to it (although this requires some knowledge of distributed elixir/erlang )

Re: Elixir Livebook is a secret weapon for documentation

#47

For NodeJS enthusiasts, Check out Docusaurus (by Meta). For Markdown Docs, Markdown Blogs, and JSX-static pages - https://docusaurus.io - https://docusaurus.io/docs/next/api/themes/@docusaurus/theme...

This is about live "documentation". Docusaurus doesn't have programmable cells linked to live processes or systems. Docusaurus is fantastic, but it's static. Livebooks are like next-generation REPLs with slick UI, security, reproducibility, etc.

Re: Elixir Livebook is a secret weapon for documentation

#48

Sorry for asking a dumb question, but how is this different from using Jupyter to write your interactive documentation/runbooks and interactive tests?

> how is this different from using Jupyter It requires you to run a far less common tech stack and limits your hiring to a vanishingly small subset of developers. Paradoxically, that may be a good thing.

This is just, wrong. There's actually a huge number of Elixirists, but after this long in the game, we're used to cynical elitists...

Re: Elixir Livebook is a secret weapon for documentation

#49
Today, in a very round-about way, one could use a livebook as if it were a blog post: download-install Livebook on your machive, download the blog post livemd file, run it locally.

Here's an example. Note in the first paragraph a link to the post as a livemd file: https://genericjam.com/blog/image-processing

If you go through the steps, you'll notice that the livemd isn't stylized as a blog post. This is where the next opportunity lies: creating beautiful blog posts as livebooks, and without the need to install and run a livebook server locally.

Re: Elixir Livebook is a secret weapon for documentation

#50
post #9

Earlier quoted context omitted.

To do so much with it you need to know Elixir or Erlang ;)

Fwiw, I’ve been using Elixir professionally for 5 or so years and even created a few open source libraries. Never once had to touch Erlang.

Erlang is very nice. I prefer it for writing libraries nowadays. It’s much easier to use Erlang from Elixir than the other way around.
Post reply on HN