tRPCttRPC
Powered by
MayhulM
tRPC•14mo ago•
9 replies
Mayhul

Migrating to use Superjson

I currently have a tRPC router that is being used by a web app & React native client. My current version does not use superjson. I want to start using superjson as my transformer. Is there an easy way for me to make this migration?

When I tried just starting to use Superjson, our React native client started running into errors because the old mobile client was not using superjson but the server was. I wish I could access context in my transformer so I could choose to only do the transformation for new clients. Any other ideas on how I can make the switch-over while maintaining backwards compatibility for older clients?
tRPCJoin
Move Fast & Break Nothing. End-to-end typesafe APIs made easy.
5,015Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Superjson "undefined"
epicmau5timeEepicmau5time / ❓-help
3y ago
How to use output validation for dates? (Zod, SuperJSON)
fengFfeng / ❓-help
2y ago
SuperJson ESModule error
BillyBobBBillyBob / ❓-help
3y ago