Skip to content

Commit c1dbc2f

Browse files
authored
(docs) Update title for Reusable Snippets page and tweak wording (#944)
1 parent fb83c88 commit c1dbc2f

File tree

2 files changed

+13
-7
lines changed

2 files changed

+13
-7
lines changed

fern/products/docs/pages/component-library/custom-components/custom-react-components.mdx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,16 @@ title: Custom React Components
33
subtitle: Add your own React components to enhance your docs
44
---
55

6+
<Markdown src="/snippets/pro-plan.mdx"/>
7+
68
You can extend Fern's built-in component library by adding your own custom React components.
79
This allows you to create unique, interactive elements that match your documentation needs.
810

9-
<Note>Setting up custom react components is part of the pro plan.</Note>
11+
<Note title="Defining a constant">
12+
Don't use a React component to define a constant. Instead, consider using [reusable snippets](/docs/writing-content/reusable-markdown).
13+
</Note>
1014

11-
## How does it work
15+
## How does it work?
1216

1317
<Steps>
1418
### Create a React component

fern/products/docs/pages/component-library/custom-components/reusable-markdown.mdx

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,19 @@
11
---
2-
title: Reusable Markdown
3-
description: Reusable, custom markdown to keep content in sync. Edit once, update everywhere.
2+
title: Reusable snippets
3+
description: Reusable, custom markdown snippets to keep content in sync. Edit once, update everywhere.
44
---
55

6-
Keep your documentation DRY (Don't Repeat Yourself) by defining a reusable snippet once, and then referencing it in multiple places. This way, you only need to update the snippet in one place to keep all references in sync.
6+
Keep your documentation DRY (Don't Repeat Yourself) by defining a reusable Markdown snippet once, and then referencing it in multiple places. This way, you only need to update the snippet in one place to keep all references in sync.
7+
8+
Reusable snippets work well for constants (API limits, subscription prices, version numbers), repeated warnings or notes, and standardized formatting blocks.
79

810
## Create a reusable snippet
911

10-
To use reusable snippets, start by creating a new folder in your `fern` project called `snippets`. Inside the `snippets` folder, create a new file for each snippet you want to define.
12+
To use reusable snippets, start by creating a new folder in your `fern` project called `snippets`. Inside the `snippets` folder, create a new Markdown file for each snippet you want to define.
1113

1214
For example:
1315

14-
```bash
16+
```bash {3, 6-8}
1517
fern
1618
└─ pages
1719
└─ my-tutorial.mdx

0 commit comments

Comments
 (0)