(async () => {
const token = 'secret_api_token'
const notionClient = new NotionClient(token, '2022-02-22')
const pageId: string = 'pageId'
const page = await notionClient.getPage(pageId)
const blocs = await notionClient.getBlocks(pageId)
const options: HtmlConfig = {
separator: '\n\n'
}
const html = blocs.reduce((acc: string, block) => acc += block.render(options) , '')
console.log(html)
})()
-
Notifications
You must be signed in to change notification settings - Fork 0
License
LeadcodeDev/notion-parser
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
License
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published