From c04e5fbc19af5ffbd2332ca23885803c56682726 Mon Sep 17 00:00:00 2001 From: Trang Le Date: Wed, 29 Jun 2022 19:01:17 +0700 Subject: [PATCH 1/2] docs: add explanation for NotionRenderer --- packages/react-notion-x/readme.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/packages/react-notion-x/readme.md b/packages/react-notion-x/readme.md index fcffc919..daed32b0 100644 --- a/packages/react-notion-x/readme.md +++ b/packages/react-notion-x/readme.md @@ -10,6 +10,22 @@ ## Docs +One of the most frequently export from React Notion X is `NotionRenderer`, a component that streamlines the rendering Notion content into HTML. + +It requires the mandatory prop `recordMap`, which is the result of querying a Notion page by calling `getPage` method from `notion-client`. + +In addition, it accepts the following optional props: + +- `mapPageUrl`: Function for rewriting path to another Notion page if it is linked to in the given page's content. +- `header` and `footer`: Set the components to be used for rendering `
` and `