Skip to content

Commit 80384c6

Browse files
authored
Remove docs around snippets config (#2436)
We are refactoring the snippets solution this removes the documentation around that solution and refactors it
1 parent b46531c commit 80384c6

File tree

3 files changed

+2
-28
lines changed

3 files changed

+2
-28
lines changed

create/reusable-snippets.mdx

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -8,22 +8,6 @@ One of the core principles of software development is DRY (Don't Repeat Yourself
88

99
Snippets do not render as standalone pages. You must import them into other files.
1010

11-
## Configure snippet folders
12-
13-
By default, any file in a folder named `snippets` is treated as a snippet. You can configure additional custom folders to contain snippets with the `snippets` field in your `docs.json`.
14-
15-
Add [glob patterns](https://code.visualstudio.com/docs/editor/glob-patterns) to the `snippets` array in `docs.json` to specify which folders contain snippets.
16-
17-
```json docs.json
18-
{
19-
"snippets": [
20-
"components/**",
21-
"shared/reusable/**",
22-
"shared/common-component.mdx"
23-
]
24-
}
25-
```
26-
2711
## Create snippets
2812

2913
Create a file in a snippet folder with the content you want to reuse. Snippets can contain all content types supported by Mintlify and they can import other snippets.
@@ -32,7 +16,7 @@ Create a file in a snippet folder with the content you want to reuse. Snippets c
3216

3317
To use snippets, import them into pages using either an absolute or relative path.
3418

35-
- **Absolute imports**: Start with `/snippets/` or your custom snippet location for imports from the root of your project.
19+
- **Absolute imports**: Start with `/snippets/` for imports from the root of your project.
3620
- **Relative imports**: Use `./` or `../` to import snippets relative to the current file's location.
3721

3822
<Tip>

customize/react-components.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ The counter renders as an interactive React component.
9292

9393
## Importing components
9494

95-
To import React components in your MDX files, the component files must be located in a snippet folder. By default, this is the `/snippets/` folder. You can [configure additional directories](/create/reusable-snippets#configure-snippet-folders) to contain snippets in your `docs.json`. Learn more about [reusable snippets](/create/reusable-snippets).
95+
To import React components in your MDX files, the component files must be located in the `/snippets/` folder. Learn more about [reusable snippets](/create/reusable-snippets).
9696

9797
### Example
9898

organize/settings.mdx

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -643,16 +643,6 @@ This section contains the full reference for the `docs.json` file.
643643
</Expandable>
644644
</ResponseField>
645645

646-
<ResponseField name="snippets" type="array of strings">
647-
Specify additional folders for reusable snippets using [glob patterns](https://code.visualstudio.com/docs/editor/glob-patterns). Any files in folders matching these patterns are snippets, in addition to the default `/snippets/` folder.
648-
649-
```json Example snippets configuration
650-
{
651-
"snippets": ["components/**", "shared/shared-file.mdx"]
652-
}
653-
```
654-
</ResponseField>
655-
656646
<ResponseField name="contextual" type="object">
657647
Contextual menu for AI-optimized content and integrations.
658648

0 commit comments

Comments
 (0)