Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(templates): add custom converter, and comments for static rendering a page #10886

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

stuckinsnow
Copy link

What?

This PR adds a custom converter to RichText, plus comments in [slug]page.tsx. Currently, it's unclear how to add additional converters to the RichText component, with no instructions or example components on how to add more.

Why?

The templates serve as examples for building a project. Since some users may be new to Payload, they might not know how to add a custom converter. While documentation exists, custom converters are an extremely common need, so including an example is pragmatic.

For [slug]page.tsx, many users encounter build issues due to database access requirements. In some cases, I'd argue generating pages at build time is unnecessary. The added comment preserves the original code while clarifying how to avoid these issues.

- instructions to generate static pages at runtime
- add a custom paragraph converter with instructions for removal.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant