fern-api / fern

Input OpenAPI. Output SDKs and Docs.
https://buildwithfern.com
Apache License 2.0
2.69k stars 151 forks source link

[Feature] Interpret frontmatter header in reusable snippets #5212

Open aweaver89 opened 2 days ago

aweaver89 commented 2 days ago

Problem description

If I want to make a modification to frontmatter values that goes across all docs that reusable content, I currently have to go into each page and add or modify the values.

It would be very helpful if I could configure a default value for the frontmatter metadata so that it automatically applies across all of the docs that use it.

Why would it be useful?

You'd be able to apply metadata changes much more easily.

Describe the solution (optional)

I want to disable feedback for all of my pages that are being generated using a base template.

I can just add

---
hide-feedback: true
---

to the top of the snippet that is being used and this will then be applied to all of the rendered versions.

Similarly, if one of the pages I want to go against the initial template, I can override by adding

---
hide-feedback: false
---

which will then override the template value.