JasonEtco / create-an-issue

A GitHub Action for creating a new issue from a template file.
MIT License
267 stars 83 forks source link

Add validation to issue templates' front matter #143

Closed JasonEtco closed 1 year ago

JasonEtco commented 1 year ago

It currently pulls in the front matter of the issue template, but doesn't assert that it has the required fields or any invalid fields. For example, if an issue template doesn't include a title front matter attribute, the Action fails because it can't render the title. That's expected, but the error message is confusing and not specific.

We should implement a check against a defined schema, to say "does this front matter match this schema". Using Joi or Zod something similar.