News for hackers. Stuff that matters.
Re:Donald Knuth was framed (2020) by tlarkworthy on Sunday May 08, 2022 @03:30AM (#31302025)
I am super excited by https://observablehq.com which has made an out-of-the-box literate programming environment for Javascript zero configuration (like Knuth's it has a non-linear execution order). Since switching to literate programming I have found myself adopting a documentation-driven-development methodology, where I ponder about the purpose of the notebook in the introduction, and because I reread it every time I open the notebook, the clarity of the software goes up, which also feedbacks into the ongoing development process too.

It takes a little while before habits change, but I think I have learnt more in the last year at age 40 than I did in my first year of undergraduate aged 19.

An aspect of Observable which is particularly compelling since Knuth is the fact that inter-notebook dependencies are hyperlinks, so these are not standalone literate programming artifacts, but they are a graph of explanation too. You can learn a lot by surfing notebook dependencies. Bundling code with documentation is such a win.

The other thing about Observable is the cells are reactive, so your documentation is not necessarily static either. You can provide animated interactive explanations too.

More info on the different types of content you can embed

https://observablehq.com/@observablehq/cell-modes

More info on the spreadsheet like execution ordering:

https://observablehq.com/@observablehq/observables-not-javas... More info on the literate programming support

Re:Donald Knuth was framed (2020) by brabel on Sunday May 08, 2022 @06:46AM (#31302911)
Hm, do you know emacs with orgmode Babel[1]?

This seems to be re-inventing that.

https://orgmode.org/worg/org-contrib/babel/intro.html

Re:Donald Knuth was framed (2020) by tlarkworthy on Sunday May 08, 2022 @02:45PM (#31306877)
Kinda but observable is more because the notebooks cells reactively recompute. And it's written in javascript and ran in a browser so you have the languages proper development tooling integrated (e.g. chrome Dev tools). And you can easily share it as its the web.
Re:Donald Knuth was framed (2020) by brabel on Monday May 09, 2022 @04:33PM (#31319343)
> observable is more

Hm, that's really relative... on Babel, you can also have reactive cells, and while it's true that having Obervable run on the web + JS is great, I could say that Babel "is more" because it supports pretty much any language, not only JS, and does not require an internet connection to work.

Re:Donald Knuth was framed (2020) by kwertyoowiyop on Sunday May 08, 2022 @09:03AM (#31303636)
How would programmers even keep themselves busy (I was going to type ‘get promoted’) if they stopped reinventing things badly?
Re:Donald Knuth was framed (2020) by sph on Sunday May 08, 2022 @04:58AM (#31302383)
Sounds like an ad, it's probably worth disclosing that you seem to be affiliated with Observable. Correct me if I'm wrong.
Re:Donald Knuth was framed (2020) by tlarkworthy on Sunday May 08, 2022 @05:11AM (#31302443)
I am a just fan and rapid user. I am so enthusiastic about it I am an (unpaid) ambassador.

https://observablehq.com/ambassadors

I am trying to build a serverless compute layer on top of observable.

https://observablehq.com/@endpointservices/webcode

If I was shilling webcode.run then I would think a disclosure would be appropriate, but as I was just talking about how great Observable is as a literate programming env, I do not think I have anything to disclose.

Re:Donald Knuth was framed (2020) by lepineko on Sunday May 08, 2022 @04:09AM (#31302190)
"non-linear execution order" ? I can't see how it's kind of spreadsheet moreover you don't really do metaprogramming BEFORE execution which is more what I understand about literate programming.
Re:Donald Knuth was framed (2020) by tlarkworthy on Sunday May 08, 2022 @05:07AM (#31302424)
the topological dependency order of cells is computed, and only (logically) downstream dependencies are recomputed on a code change. See https://observablehq.com/@observablehq/how-observable-runs
Re:Donald Knuth was framed (2020) by hueyluey on Sunday May 08, 2022 @04:22PM (#31307808)
Is "topological dependency order of cells" different from what an average person would understand from saying "dependency order of cells"?
Re:Donald Knuth was framed (2020) by tlarkworthy on Monday May 09, 2022 @02:49AM (#31311332)
yeah it's the technical name for the intuitive sort order you need for a graph of dependencies.