Skip to content

Commit

Permalink
Add a schema_hook for generating JSON schemas
Browse files Browse the repository at this point in the history
Previously custom types needed to be annotated with
`Meta(extra_json_schema=...)` to be supported in `msgspec.json.schema`.
This adds a new `schema_hook` which supports generating json schemas for
custom types without requiring an extra annotation.
  • Loading branch information
jcrist committed Dec 7, 2023
1 parent ad5801d commit ba316c4
Show file tree
Hide file tree
Showing 4 changed files with 297 additions and 243 deletions.
Loading

0 comments on commit ba316c4

Please sign in to comment.