dsh-tool-notion

Convert Notion blocks and Markdown in both directions, with no API client and no external dependency. A Notion paragraph is an array of rich-text runs while Markdown says one string, so the two directions are a split and a merge rather than a pair of inverses — rich-text runs are cut at every annotation boundary one way and re-merged the other, with fences widened when the content already contains backticks. Reports every lossy step instead of swallowing it.

Overview

Convert Notion blocks and Markdown in both directions, with no API client and no external dependency. A Notion paragraph is an array of rich-text runs while Markdown says one string, so the two directions are a split and a merge rather than a pair of inverses — rich-text runs are cut at every annotation boundary one way and re-merged the other, with fences widened when the content already contains backticks. Reports every lossy step instead of swallowing it.

Installation

Install from npm

dsh plugin --profile web add dsh-tool-notion

Resolves a published tarball rather than cloning the repository, and installs without any extra setup. Swap `web` for your profile name if you run another one.

Install from GitHub

dsh plugin --profile web add github:yuehancn/dsh-tool-notion

Installing from GitHub runs the project's build script, which pnpm blocks until you allowlist it — run the command once and pnpm prints the exact key to add under `allowBuilds` in ~/.dsh/profiles/web/pnpm-workspace.yaml.

Version compatibility

Compatibility is unconfirmed. Check the project documentation for supported versions.

Installation notes

  • May run terminal commands