Hello. This is probably a very basic question but I know next to nothing about scripting. I need help creating a draft template that can be easily run via an action. I have an existing template (see below) that sets the note title and then some very basic standard sections. How would I add the date in MMDDYYYY format to the end of the top line of the “Bi-Weekly Meeting” line? I’m targeting the creation date of the draft.
I’m guessing it has something to do with [[created]]?
/* Create new draft with template text and tag assigned. */ // create template const template = `Bi-Weekly Meeting - Action Items - Notes `; // create the draft var d = Draft.create(); d.content = template; d.addTag("meeting"); d.update() // load in editor and focus for editing editor.load(d); editor.focus()