- Category pages
- if there is no category for a post, it goes into the /posts/ url
- otherwise, there is an index for a category. Example /projects
- Tags
- Used to tag context of a project. (personal, company, etc.)
Uses GitHub Projects (v2) as CMS.
- Issue = Page or Post
- Category Pages (using custom field in the GitHub project)
- Tag Pages using GitHub Labels
- MDX Components
- public editing option
- Live updating site without a redeployment to Vercel. Just need to refresh the homepage, and it checks for new issues and builds the pages.
- Set publish tag (only Issues with this tag will be published)
- (Optional) Set up Issue Templates (For Post Templates, etc.)
- Create a Project
- Enter the Project Number ___ in the configuration file
githubCMS.config.ts
- Create Custom fields (fields with no space will be used as is, if the name has a space it will turn to camelCase)
- Category
- Cover Image
- Publish Date
Need to use the KV store of cloudflare (or anywhere else) to convert between slugs and issue IDs because the GitHub api only allows fetching issues by ID.
- Instructions: https://giuseppegurgone.com/vercel-cloudflare-kv
- GITHUB_TOKEN
- CLOUDFLARE_TOKEN
Example:
{
publish_tag:'',
org_project:false,
username:"", // use Organization username if Organization
project_num: 1,
}
- Create a new issue in the project and title it the category name (e.g. Posts)
- Set a subtitle that will show up on the category page as a description.