I might just be missing something, but I couldn’t find anything in the user guide what I’m looking for. I’m wondering if there’s any kind of functionality like iA Writer’s Content Blocks, where you can include a reference to another file, the content of which will appear in Preview of that file, maybe by referencing the UUID or something? I see you can cross-link to another draft but not seeing a way to get the text of that draft to appear in the Preview, at least not with the delivered vanilla Preview action.
If this is impossible it would be useful for using repeating snippets of texts in multiple Drafts MD output.
I also have Marked—if this is possible somehow through that, I might just be missing exactly how.
Thanks for any help!
It’s not a “built-in” feature to expand markup, but can be done pretty easily in actions. I put up a couple of example actions which transclude drafts linked using the
[[cross-link]] (docs) syntax to previews, or to compile them into a new draft.
Excellent! Thank you for the quick response. I’ll play around with these.
In case it is useful, there’s also an action in the ThoughtAsylum action group called
TAD-Exploded Markdown Preview. It’ll do transclusion of other drafts through the wiki links (just one level to avoid infinite recursive loops), file template references, convert Drafts checkbox syntax to HTML checkboxes, and load local images (no web server required, just a bit of prep of the image through a shortcut or Automator-based quick action depending upon your platform).
There’s a walkthrough of the various aspects in this post, including links to image preparers.
Thanks for the heads up! I actually have it on my to do list to set aside some time to look at your action group; looks like there’s a lot of useful stuff in there.