Replies: 5 comments 8 replies
-
@naturecodevoid Thanks for the suggestion! This is something I've wanted to look into, so I really appreciate the link to see how they support it. Ideally I wouldn't want to rely on another plugin, but I'm guessing JS Engine and the more popular Custom JS does a bunch of stuff under the covers that's needed that I'm not thinking of. What's the difference between these two? I'd probably aim to support the more popular of the two first. |
Beta Was this translation helpful? Give feedback.
-
See also this discussion about scripting and an API. |
Beta Was this translation helpful? Give feedback.
-
Support for JS Engine, Dataview, and Templater is now available in the beta! |
Beta Was this translation helpful? Give feedback.
-
@amsam0 Support for JS Engine is now in the latest release. |
Beta Was this translation helpful? Give feedback.
-
@amsam0 I've been thinking about your suggestion:
A couple thoughts:
|
Beta Was this translation helpful? Give feedback.
-
Hi, this plugin looks really useful and I would love to start using it in my vault as a replacement for some Meta Bind buttons I use. However, most of these buttons are powered by custom javascript code run through the JS Engine plugin. While the note toolbar plugin supports running commands, JS Engine's "run JavaScript file" command requires you to pick a file when you run it, making it suboptimal for usage with Note Toolbar. It would be really nice if Note Toolbar had a item type that runs a JavaScript file.
As for actual implementation details, I'm not sure if JS Engine has a proper API but I know Meta Bind uses it so that may be worth taking a look at. (After a quick look at JS Engine's source code, it seems like the plugin'sHere's a link to how Meta Bind does it: https://github.com/mProjectsCode/obsidian-meta-bind-plugin/blob/0151349165be77a8e70a8f6f969053baceb366f4/packages/obsidian/src/ObsidianInternalAPI.ts#L79-L106api
property has an "internal" API class that is used for executing files)Beta Was this translation helpful? Give feedback.
All reactions