我无法通过遵循Gridsome的docs来使用NeflifyCMS设置Gridsome
设置Netlify config.yml的代码片段
collections:
- name: "posts"
label: "Posts"
folder: "posts"
create: true
slug: "{{slug}}"
fields:
- {label: "Title", name: "title", widget: "string"}
- {label: "Excerpt", name: "excerpt", widget: "string"}
- {label: "Publish Date", name: "date", widget: "date"}
- {label: "Body", name: "body", widget: "markdown"}我转到Graphql Playground并打开Docs选项卡,看到"allPost“查询,但当我查看它时,"title”没有被识别为post下的字段,而"belongsTo“却被识别为。如果你试图查询"title“,你会得到错误的"Cannot query field 'title‘on type 'Post'”。
我不知道"belongsTo“是从哪里来的,也不知道如何修复它。这是一个Netlify bug还是一个Gridsome问题?
发布于 2020-04-24 03:08:39
长话短说,文档是错误的,请观看此视频,而不是https://www.youtube.com/watch?v=ryP1RMA7P9Y
https://stackoverflow.com/questions/61392687
复制相似问题