Zettelkasten Forum


[Plugin] TOC from selection

Hi zettlers!

I am new to this forum but hopefully it is okay to start participating by providing a plugin for The Archive app.

I am mainly worrying about violating ToS in this particulary paragraph: "If you want to promote your product (app, book, course, ...) and/or your writing, you should be an active community member or first ask the mods for permission. Ignoring this leads to immediate deletion of your account and your post." If plugins are considered as aforementioned apps, I apologize and ask for deletion of this post.

I have been using an Automator quick action in MacOS to make those nice "dotted" structure-note TOCs. Since TA has a plugin system I thought I might try to rewrite my Automator/Python thingy as a native plugin. And it worked! :smiley:

Usage: select line(s) and execute

Example, text before:
before

Text after:
after

Caveats: I am not very familiar with JavaScript, so my experience with C might have influenced the way I wrote the code. If you are more professional with JS, feel free to modify it as you please.

Cheers!
JW

Comments

Sign In or Register to comment.