I have a couple of (relative) newb questions about Nimble Publisher that I can’t quite work out.
I have it (more or less) working but two questions remain:
-
What is the best way to handle a markdown file with an image ref in it? For example, let’s say that the original markdown file was in a directory called
dir/
and in that directory is an image calleddir/image.png
. If the markdown file is in the same directory (iedir/markdown.md
I could use the standard markdown image reference tag
and the markdown viewer or renderer would create an<img src="./image.png">…
tag from the markdown. However, because of the way that the routes are set up, that image url ends up being interpreted as an id for a blog post, which of course it can’t find. I can’t be the first person to ever try to do this so there must be an idiomatic way to handle URIs embedded in the markdown file or a way to configure the routes so that markdown is handled by nimble by images are and other content are treated as normal urls. -
I want to control the way that the HTML is emitted from the markdown processor so that I can style it. At the moment, a markdown
# Heading
is being rendered simply as<h1>Heading</h1>
. But what I need to do is control the styling of the emitted HTML. Again, I can’t be the first person who has ever needed to do this, but I can’t find from the docs what the best way to handle this would be.
Any ideas or even a link to an example or some docs for either problem would be very helpful. Thanks.
PS: I originally posted this on GitHub to the NimblePublisher repo here, but was asked to cross-post here by @josevalim.