Is your feature request related to a problem? Please describe.
Consumers of Prismic's webhooks currently do not have an official way to type the incoming data. Developers will need to write the types in their own projects.
Describe the solution you'd like
@prismicio/types can provide these types to developers. As the API changes, or new webhooks are added, this library can be updated to ensure developers have the latest types.
Describe alternatives you've considered
Developers can write these types in their own project. They can also minimize the types to include only what is relevant to their application. This can lead to extra friction when adopting Prismic webhooks into an application as it requires additional work.
Additional context
The following types are taken from gatsby-source-prismic and could be used as a reference when adding to this library.
Is your feature request related to a problem? Please describe.
Consumers of Prismic's webhooks currently do not have an official way to type the incoming data. Developers will need to write the types in their own projects.
Describe the solution you'd like
@prismicio/types
can provide these types to developers. As the API changes, or new webhooks are added, this library can be updated to ensure developers have the latest types.Describe alternatives you've considered
Developers can write these types in their own project. They can also minimize the types to include only what is relevant to their application. This can lead to extra friction when adopting Prismic webhooks into an application as it requires additional work.
Additional context
The following types are taken from
gatsby-source-prismic
and could be used as a reference when adding to this library.(Based on types from @MarcMcIntosh)