crossnote
crossnote copied to clipboard
increase headings level for imported md documents
Hi,
I have a problem with the headings of imported markdown documents. For example:
main.md:
# Main document
@import "child.md"
child.md:
# Child document
## Inner child header
This produces result.md:
# Main document
# Child document
## Inner child header
Expected result:
# Main document
## Child document
### Inner child header
I sometimes use @import directive to separate large documents into sections.
main.md
# document title {ignore=true}
# Overview {ignore=true}
[TOC]
@import "./section_1.md"
@import "./section_2.md"
@import "./section_3.md"
section_1.md
# Section 1
## Section 1.1
some contents here...
This PR does not fit into existing use cases and I cannot accept it as a user of MPE.
You can solve this problem by adding additional attributes to @import directive. Of course, this feature is disabled by default.
It is recommended that you create an issue to discuss what options should be added.