A simple npm package to convert a Notion page to a Marp Slides presentation.
H1 and H2 Heading in the notion page will be used as the slide title, and the rest of the content will be used as the slide body.
You can see the usage from getting started slides, which is also created by this package. The original notion page is here.
notion.to.slides.demo.mov
- Create an integration token in Notion
- Open the Notion page you want to convert
- Add your integration to the page
$ export NOTION_TOKEN=[your notion token]
$ npx @kromiii/notion-to-slides --url [your notion page url] --theme [marp theme] --port [port number]
You can change the theme by setting the --theme
option. The default theme is default
.
Available themes are: default, uncover, and gaia. See Marp Core Themes for more details.
Once the script is finished, it will open the browser with the slides. You can check the slides by clicking the "Print" button (cmd + P on Mac). Then you can export the slides as pdf.
$ npx @kromiii/notion-to-slides --url https://www.notion.so/khiroyuki1993/CTOA-LT-4-c2769d7bc90a4f428adae7a2192d258a --theme uncover --port 8080
Option | Description | Default | Required |
---|---|---|---|
--url |
The Notion page URL to convert | required |
|
--theme |
The Marp theme to use | default |
optional |
--port |
The port number to use | 8080 |
optional |
$ git clone
$ npm i
$ npm run start [your notion page url] -- --port [port number] -- --theme [marp theme]
MIT