Feat: support hidden widget in files collections
- Dominant language
- JavaScript
- Stars
- 19.4k
- Forks
- 3.1k
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 9
Description
Repo: chokeul8r/gncms
I am attempting to use NetlifyCMS in a Gatsby Landing Page project for the first time. My problem relates to the config.yml file and Template key field in particular. The template key is not showing up in my frontmatter and/or my graphgl query.
```yaml
backend:
name: git-gateway
branch: master
media_folder: static/assets
public_folder: assets
collections:
- label: "Pages"
name: "pages"
files:
- label: "Home Page"
name: "home"
file: "content/home.md"
fields:
- {
label: "Template Key",
name: "templateKey",
widget: "hidden",
default: "home-page",
}
- { label: Background Image, name: backgroundimage, widget: image }
- { label: Title, name: title, widget: string }
- { label: Sub-Title, name: subtitle, widget: string }
- { label: Intro text, name: intro, widget: text }
- { label: Body text, name: body, widget: text }
- { label: Profile Image, name: profileimage, widget: image }
- label: "Thank You Page"
name: "thank-you"
file: "content/thank-you.md"
fields:
- {
label: "Template Key",
name: "templateKey",
widget: "hidden",
default: "thank-you-page",
}
- { label: Title, name: title, widget: string }
- { label: Intro text, name: intro, widget: text }
- { label: Image, name: image, widget: image }
```
Contributor guide
Assessment
This issue has not been assessed yet.