@brianmmdev/notion-to-html

0.0.4 • Public • Published

notion-to-html

A simple library that converts Notion pages to HTML.

THIS LIBRARY IS STILL A WIP. MANY BLOCKS ARE NOT YET SUPPORTED. THEY WILL BE ADDED OVER TIME.

How to Use

This package uses the official Notion API, so you'll need an integration token before you can use it. To create one, follow the guide at https://developers.notion.com/docs/getting-started.

const NotionToHtmlClient = require('@brianmmdev/notion-to-html')

let integrationToken = "123123123asdASDaasdfasdf"

// Create a client and pass in your integration token.
let client = new NotionToHtmlClient(integrationToken)

// Create html using the page ID (obtained from the URL)
let html = await client.generateHtmlFromPage("salkdjfalskdujf09a87dfo98as")

More examples will be added in the future.

Support

For assistance in using this project, contact me on Twitter @brianmmdev or in my Discord at fullstack.chat.

How to Contribute

  • Fork the repository and make the changes
  • Submit a PR into this repository
  • Win

Package Sidebar

Install

npm i @brianmmdev/notion-to-html

Weekly Downloads

1

Version

0.0.4

License

ISC

Unpacked Size

27.7 kB

Total Files

4

Last publish

Collaborators

  • brianmmdev