You thought hidden formulas or black magic were huge?
This is huge.
What if I told you —
Anything you can do manually in Coda can be turned into an action!
How about an action to truly reorder rows, without compromising on manual dragging?
Or hiding and showing columns by a click of a button?
Or actually adding columns through an action, in those very few cases when you actually need it?
And all the other repetitive things that we all collectively spent hours doing manually — imagine we could finally automate most of these!
How??
I tapped into the frontend code of Coda — the ~400k lines of code that run the whole Coda editor.
I started exploring the document model — different modules and APIs within Coda’s frontend JS code responsible for pages, tables, formulas etc. The code is minified and obfuscated, and looks like an illegible mess. But I was so deprived of some Coda hacking lately, I eagerly took it up for a challenge
To make it more accessible, I created a CodaTricks Chrome Extension. Right now it is but a proof-of-concept, but I have ambitions to develop it into a decent ‘Coda Dev Tools’ addon that would automate repetitive Coda building tasks, such as:
- quickly generating databases (pages and tables)
- bulk-editing column formats (e.g. setting all date/time columns to the same format in a single click)
- quickly generating helper tables of various sorts
- generating ‘flat’ pivot and transposed tables out of existing tables in a single click
and other things that take forever to do by point-and-click. Technically the extension could even perform true realtime 2-way editing provided that both docs are opened at the same time and the extension can sync the edits (although I still believe it’s a job better fit for Crossdoc Sync Tables Pro and/or webhooks)
The way the extension works with CFL is rather ingenious too.
At first I was thinking of a Pack-based setup (requiring a backend and a realtime messaging mechanism to deliver updates back to the browser) and I implemented that. But then I realized it had to be more straightforward. So I found a way to hook up to the CFL directly! The way this works is:
-
Anywhere in your action formula you make a call to a special ‘bogus’ pack like this:
It doesn’t have to be a single call on the formula — in fact it can be a 50-line long formula with many
RunExtensionAction
calls like this, and it will still run fine! -
The extension intercepts calls to this particular pack and redirects them to the extension code, executing them immediately on the client side!
In the case the extension is not installed, the pack will simply show an error saying so. In fact that’s all that the pack does: it throws an error
That’s because the code shall never reach it.
How to get it?
In a nutshell: fund it.
If you’re seriously interested in me developing this tool sooner rather than later, please DM me or write at paul@codatricks.com. If someone is eager to (collectively?) fund my R&D on this front I’ll be able to prioritize this project, otherwise I’ll have to put it on a pause for a while and work on things that can bring my family bread and butter in the shorter run.
Right now there’s not much but a proof of concept. It works though; the gifs above are real. If you’re interested in getting it already and you’re open to fund it, I won’t just share it with you but will also take requests for the features you want to automate first
When eventually the extension is out for GA, I’ll most likely make it a paid addon. My rationale for this is that it’s not an essential tool (in which case I’d gladly open it up) but a valuable extra that’s capable of drastically saving time and implementing new workflows. This addon can give commercial advantage to professionals, agencies, and companies, letting them build with Coda faster and making docs feel even more app-like to their users. I haven’t yet decided on how exactly but I’ll come up with some licensing for it.
Cheers!