feat: backport extended media API response #58
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Types of changes
Description
Related: https://github.com/prismicio/prismic-web/pull/134
@prismicio/react still relies on @prismicio/richtext which relies on @prismicio/types. This makes types expected from @prismicio/react inconsistent with types generated from @prismicio/client. This PR backports new media API response types for types to match (which perhaps also solves other problems)
In the near future I think we'll need a plan to update @prismicio/react not to use @prismicio/richtext anymore but @prismicio/client/richtext instead (which was my plan first, but I wasn't sure how you wanted to handle the peer dependency of @prismicio/client then as I don't think it can be promoted to a regular dependency there? (that's how it's done with Vue.js though 🤷♀️)
Checklist: