You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|`repoURL`|`string`| - | GitHub repository URL used for source code links and as default for GitChangelog |
170
170
|`contentPath`|`string`|`''`| Directory path where documentation files are located relative to repository root |
171
171
|`gitChangelog`|`object \| false`| Uses `repoURL`| Git changelog configuration or `false` to disable |
172
-
|`markdown`|`object \| boolean`|`true`|Markdown generation options or `false` to disable|
172
+
|`llms`|`object \| boolean`|`true`|LLM-friendly markdown generation options or `false` to disable |
173
173
174
174
The plugin automatically:
175
175
176
176
- Configures Git changelog functionality using the provided repository URL
177
177
- Enables source code viewing and copying features
178
178
- Constructs proper URLs for "View Source" and "Edit Page" links
179
-
- Generates markdown files for all HTML pages during build
179
+
- Generates LLM-optimized markdown files for every page using `vitepress-plugin-llms`
180
180
181
181
### Register the theme as internal dependency
182
182
@@ -206,14 +206,14 @@ For more information about why configure this, please refer to the [Server-Side
206
206
207
207
## Copy Page as Markdown
208
208
209
-
The theme automatically generates markdown versions of all HTML pages during build using the [@mdream/vite](https://github.com/harlan-zw/mdream) plugin. This enables users to easily copy page content as markdown for use with LLMs, note-taking apps, or other tools.
209
+
The theme automatically generates markdown versions of all HTML pages during build using the [vitepress-plugin-llms](https://github.com/okineadev/vitepress-plugin-llms) toolkit. This enables users to easily copy page content as markdown for use with LLMs, note-taking apps, or other tools.
210
210
211
211
### How it works
212
212
213
-
1.**Automatic Generation**: The `NimiqVitepressVitePlugin`includes the mdream Vite plugin which automatically converts HTML pages to markdown during build
214
-
2.**Development Support**: In dev mode, markdown is generated on-demand when accessing any page with `.md` extension (e.g., `/guide.html` → `/guide.md`)
213
+
1.**Automatic Generation**: The `NimiqVitepressVitePlugin`bundles `vitepress-plugin-llms`, which converts each documentation page into a dedicated `.md` file during build
214
+
2.**Development Support**: In dev mode, the plugin serves `.md` pages through the Vite dev server so you can copy or test locally without a full build
215
215
3.**Copy Button**: Each page includes a "Copy page" button that fetches the generated markdown and copies it to the clipboard
216
-
4.**Configurable**: You can customize caching, verbose logging, or disable the feature entirely through the plugin options
216
+
4.**Configurable**: You can override any `llmstxt` settings (e.g., domain, hints, additional outputs) or disable the integration entirely through the plugin options
217
217
218
218
The markdown files are saved alongside their corresponding HTML files in the build output (e.g., `getting-started.html` → `getting-started.md`).
219
219
@@ -224,12 +224,13 @@ You can configure the markdown generation or disable it entirely:
224
224
```ts
225
225
NimiqVitepressVitePlugin({
226
226
// Disable markdown generation
227
-
markdown: false,
227
+
llms: false,
228
228
229
229
// Or customize options
230
-
markdown: {
231
-
cacheTTL: 7200000, // 2 hours cache
232
-
verbose: true// Enable logging
230
+
llms: {
231
+
domain: 'https://docs.example.com',
232
+
generateLLMsTxt: true, // Enable llms.txt sitemap
233
+
generateLLMsFullTxt: false, // Keep the bundle light
233
234
}
234
235
})
235
236
```
@@ -325,34 +326,6 @@ copyOptions: source-only # Show only "View Source" button
325
326
---
326
327
```
327
328
328
-
## Custom Header Slot
329
-
330
-
Add custom content between the search bar and modules dropdown in the header navigation.
The slot appears in both desktop header and mobile sidebar (above the modules selector) in the home layout.
355
-
356
329
## Customization
357
330
358
331
This theme **has not been developed with customatization in mind**. In fact, it has the least possible amount of options on purpose as we want to keep it simple.
0 commit comments