Now when I try to use the trpc client on Next.js I get a TypeError.
What I did once I created the Next.js client, is running npm link to be able to import my appRouter.
Here is my utils/trpc.ts:
```js
import { httpBatchLink } from "@trpc/client";
import { createTRPCNext } from "@trpc/next";
import { appRouter } from "trpc-express";
function getBaseUrl() {
if (typeof window !== "undefined") return "";
if (process.env.VERCEL_URL) return
Now when I try to use the trpc client on Next.js I get a TypeError.
What I did once I created the Next.js client, is running npm link to be able to import my appRouter.
Here is my utils/trpc.ts:
```js
import { httpBatchLink } from "@trpc/client";
import { createTRPCNext } from "@trpc/next";
import { appRouter } from "trpc-express";
function getBaseUrl() {
if (typeof window !== "undefined") return "";
if (process.env.VERCEL_URL) return https://${process.env.VERCEL_URL}`;http://${process.env.RENDER_INTERNAL_HOSTNAME}:${process.env.PORT}http://${process.env.RENDER_INTERNAL_HOSTNAME}:${process.env.PORT};http://localhost:${process.env.PORT ?? 3000}http://localhost:${process.env.PORT ?? 3000};${getBaseUrl()}/api/trpc${getBaseUrl()}/api/trpc,
Join the Discord to ask follow-up questions and connect with the community