NotionX / NotionX/react-notion-x

Ability to override header?

Open
#317 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
5.4k
Forks
645
PR merge metrics
No merged PRs in 30d

Description

https://github.com/NotionX/react-notion-x/blob/015c6816c0d63743e1b57272373457022daacba5/packages/react-notion-x/src/context.tsx#L79

In NotionRenderer, if fullPage is set to true, the rendered html will include a <header> element that includes breadcrumbs. AFAICT there is no way to override this <header> and still keeping fullPage = {true}.

A scenario when users may want to set fullPage to true and rewrite <header>: use Notion as a basic CMS only. That's when the default breadcrumbs won't apply.

What do you think?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in packages/react-notion-x/src/context.tsx around line 79 and trace how NotionRenderer handles fullPage and renders the header with breadcrumbs. Determine the supported customization point needed to replace that header while retaining fullPage={true}; done means callers can provide their own header for this mode without the default breadcrumbs.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.