To-do list, but it's just one table and one row 🤯

Following this idea, I challenged myself to build a functional viable doc that would be compressed into as fewer objects as possible.

Presenting, a to-do list that fits into 1 section, 1 table, and 1 row :slight_smile:

Features:

  • Each task has a title, done status, and a user who added it
  • Create, edit, delete, check/uncheck tasks, reassign to other users.
    You can modify only the tasks assigned to you.
  • Show all tasks or only created by a specific user.
    Users are displayed for each task when All users mode is selected, hidden otherwise.
  • Show/hide completed tasks

There is an invisible limit though. Each cell can only store ~85000 bytes of data (~42500 UTF-16 characters including all the overhead JSON that’s stored for buttons and formatting). I haven’t measured it but I presume that this list can only grow so big, perhaps a hundred items or two.

The doc is here:
https://coda.io/@paul/cost-effective-to-do-list

Does this have any useful purpose? No, except showing off my skills the flexibility of Coda once again. Should you do something similar? No way, unless you absolutely know what you’re doing and it’s purely for experimenting and fun. This doc uses some black magic to make it work (particularly buttons in the tasks list) and may break without warning at any Coda update.

Take care!

11 Likes

You’ll gonna love this then @Phil_Hamilton-Schmidt :wink: Keeping it in the free tier alright

Yowzer! Love me some free tier. This doc is great! The simplicity of the end result is terrific. I’m only starting to understand SVG, no way I’ll ever make it to JSON strings. :exploding_head:

@Paul_Danyliuk Question for you, how do you go about writing your Coda formulas? Do you do it in the doc or a separate program? I use a text editor sometimes but then I miss Coda’s autofill. But in Coda there isn’t much room and pressing return or enter will close the formula. I’d love for my formulas to have this level of organization without going in and out of Coda:

Screen Shot 2020-05-04 at 5.46.28 PM

I write formulas right in the doc. Can’t imagine typing formulas without autofill. But also I found that copy-pasting formulas from external editors wouldn’t work if formulas have multiple lines. I guess that’s because I’m on Windows, and even if I switched CRLF (\r\n) to LF (\n) mode of newlines, Coda still wouldn’t parse pasted formulas beyond the first line.

When in need of a bigger formula window, I open developer tools and paste and run this snippet in the JS console:

It’s not ideal because the formula box still jumps around a lot (with this CSS it stops being fixed and adapts to the length of the longest line… usually that’s a line from formula description). Haven’t worked with CSS for quite a while, and haven’t had a chance to come up with a more solid solution.

Pressing shift+enter adds a new line. Wasn’t it you who discovered that? Oh yeah, that was @Lloyd_Montgomery. Why do I always mix you two?

Here’s a “style guide” I created:

One update: I usually keep FormulaMap(RunActions( on the same line and don’t indent. That’s because RunActions is so often used in FormulaMap, there’s little reason to put it on a separate line; it’s expected to find it on the same line (remember that the goal of line-breaking is just to make it easy to understand the formula at a glance)

2 Likes