Skip to content

Commit 82a149b

Browse files
document passing options to config markdown plugins
1 parent 31a10be commit 82a149b

1 file changed

Lines changed: 27 additions & 0 deletions

File tree

src/pages/docs/reference/configuration.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -229,6 +229,33 @@ After installing the package, pass the plugin name as a string:
229229
230230
<!-- prettier-ignore-end -->
231231
232+
If you need to pass options to a markdown plugin, you can use object syntax with the plugin name and the options it takes.
233+
234+
<!-- prettier-ignore-start -->
235+
236+
<app-ctc-block variant="snippet">
237+
238+
```js
239+
export default {
240+
markdown: {
241+
plugins: [
242+
"rehype-slug",
243+
"remark-gfm",
244+
{
245+
name: "rehype-autolink-headings",
246+
options: {
247+
behavior: "append"
248+
},
249+
},
250+
],
251+
},
252+
};
253+
```
254+
255+
</app-ctc-block>
256+
257+
<!-- prettier-ignore-end -->
258+
232259
## Optimization
233260
234261
Greenwood provides a number of different ways to send hints to Greenwood as to how JavaScript and CSS tags in your HTML should get loaded by the browser. Greenwood supplements, and builds up on top of existing [resource "hints" like `preload` and `prefetch`](https://developer.mozilla.org/en-US/docs/Web/HTML/Preloading_content).

0 commit comments

Comments
 (0)