Skip to content

Commit

Permalink
feat(server + client): streaming mutations and queries over HTTP (#5700)
Browse files Browse the repository at this point in the history
  • Loading branch information
KATT committed May 19, 2024
1 parent 4e20540 commit d468969
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/utils/trpc.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { httpBatchLink, loggerLink } from '@trpc/client';
import { unstable_httpBatchStreamLink, loggerLink } from '@trpc/client';
import { createTRPCNext } from '@trpc/next';

import type { inferRouterInputs, inferRouterOutputs } from '@trpc/server';
Expand Down Expand Up @@ -62,7 +62,7 @@ export const trpc = createTRPCNext<AppRouter, SSRContext>({
process.env.NODE_ENV === 'development' ||
(opts.direction === 'down' && opts.result instanceof Error),
}),
httpBatchLink({
unstable_httpBatchStreamLink({
url: `${getBaseUrl()}/api/trpc`,
/**
* Set custom request headers on every request from tRPC
Expand Down

0 comments on commit d468969

Please sign in to comment.