I maintain a large site that has various
Markdown content items (
not layout items) that appear in several HTML pages.
My content includes are arranged in subfolders inside an '_inc' folder.
I have the following in 'Rules':
compile '/_inc/*' do
filter :kramdown
end
(i've also tried '/_inc/**')
and:
route '/_inc/*' do
nil
end
In my Markdown content files I've used both:
<%= @items['/_inc/subfolder/mdFilename/'].compiled_content %>
and also the wildcard: '/_inc/subfolder/mdFilename.*'
But both yield the raw code in the HTML file, with 'smart quotes' around the path - which may be an issue - e.g.:
<%= @items[‘/_inc/subfolder/mdFilename.*/’].compiled_content %>
The Kramdown warning is:
kramdown warning(s) for <Nanoc::CompilationItemRepView item.identifier=/subfolder/mdFilename/ name=default>
No link definition for link ID ''/_inc/subfolder/mdFilename.*'' found on line 6
What's the canonical way to use content includes?
Nanoc version: 4.9.3