Import & Export
.mdTree can import a hierarchy from MkDocs or Docusaurus config files, and export back to those formats when you're ready to publish.
Importing from MkDocs
- Create a new project in .mdTree for your docs (use ⋮ → Projects → + New project on the project chip)
- Copy your
mkdocs.ymlinto the project folder atprojects/{name}/mkdocs.yml - Copy your markdown files into
projects/{name}/markdowns/ - Click ⋮ on the project chip, then Import from... → MkDocs
The hierarchy is built from the nav: section of your config. Category-only nodes (sections with no page of their own) are flattened — their children are promoted up one level.
Importing from Docusaurus
- Create a new project in .mdTree for your docs (use ⋮ → Projects → + New project on the project chip)
- Copy your
sidebars.js(orsidebars.ts) into the project folder atprojects/{name}/sidebars.js - Copy your markdown files into
projects/{name}/markdowns/ - Click ⋮ on the project chip, then Import from... → Docusaurus
If neither sidebars.js nor sidebars.ts is found, you will be prompted for the filename.
Exporting to MkDocs
Click ⋮ → Export to... → MkDocs. The exported mkdocs.yml is written to projects/{name}/mkdocs.yml. Copy it back to your MkDocs project to use it.
Exporting to Docusaurus
Click ⋮ → Export to... → Docusaurus. The exported sidebars.js is written to projects/{name}/sidebars.js. Copy it back to your Docusaurus project.
Notes
- Import replaces the current hierarchy entirely
- Markdown files referenced in the imported config must already exist in
markdowns/— import does not copy files - Export reflects the current hierarchy at the time of export; run it again after any reorganization