fonsp / Pluto.jl

🎈 Simple reactive notebooks for Julia
https://plutojl.org/
MIT License
4.94k stars 285 forks source link

Automatic sorting of notebook cells? #974

Closed oschulz closed 3 years ago

oschulz commented 3 years ago

Just an idea (not fully thought out either, I'll admit) - sorry if this has already been discussed.

Pluto's non-linear evaluation order let's users have cells in basically any order - while a notebook evolves (users jumping around and inserting things here and there), that can potentially lead to notebooks that are very non-linear and hard to read (since humans kinda to tend to read in a top-down fashion), even though they'll be functioning perfectly fine.

Would it be helpful to have a "sort my notebook" button that performs a topological sort of the cells according to the dependency DAG?

The problem is, what to do with text cells? One could treat all text cells before a code cell as "attached" to it, and move them when the code cell get's moved during sort - but is this what the user would want?

fonsp commented 3 years ago

Can you post this suggestion to our built in feature request system? https://github.com/fonsp/Pluto.jl/issues/182

oschulz commented 3 years ago

Uh, I tried, but I get this

This page isn’t working
localhost didn’t send any data.
ERR_EMPTY_RESPONSE