github unnoq/orpc v0.18.0

latest releases: v1.8.7, v1.8.6, v1.8.5...
8 months ago

🚨 Breaking Changes Alert 🚨

The Fetch Handler APIs have been rewritten! Please refer to the updated documentation for details: Documentation.

What's New?

Here’s a quick example of the updated API:

const openapiHandler = new OpenAPIServerlessHandler(router, {
  schemaCoercers: [
    new ZodCoercer(), // Add your custom coercers here!
  ],
});

const orpcHandler = new ORPCHandler(router);
const compositeHandler = new CompositeHandler([openapiHandler, orpcHandler]);

// Usage examples:
openapiHandler.fetch(/***/);
orpcHandler.fetch(/***/);
compositeHandler.fetch(/***/);

Key Highlight 🚀

The introduction of schemaCoercers enables support for multiple schema types, paving the way for enhanced flexibility and the Smart Conversion feature.

Check it out and explore the possibilities!

   🚨 Breaking Changes

  • server: Fetch handler rewrite and tests with multiple coercers support  -  by @unnoq in #57 (93e7a)
    View changes on GitHub

Don't miss a new orpc release

NewReleases is sending notifications on new releases.