fastify-type-provider-zod
fastify-type-provider-zod copied to clipboard
Hybrid bundle (ESM, CJS)
As some libraries already moved away from CommonJS and delivering ESM only builds, we startet moving our projects over to using ESM as well.
Now when importing ZOD in our project, we run into the problem, that the ESM build of zod is used while zod loaded through this library will use the CJS build, leading to zod having troubles with some schemas (because it's using instanceof internally).
Moving forward it would be great if you could bundle the lib with both CJS and ESM bundles.
Sure, that's something that we can do
Should be addressed by
- https://github.com/turkerdev/fastify-type-provider-zod/pull/153
- https://github.com/turkerdev/fastify-type-provider-zod/pull/169
Now v5.0.1 exports both CJS and ESM files