Replies: 1 comment
-
Would recommend not using a custom server and building around API routes to begin with |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I am using the next.js custom server with koa in my project and trying to turn off
useFileSystemPublicRoutes
. But then I could not make the preview mode works properly.In the custom server file I have this router for
api/preview
.This is the
/api/preview.ts
file:I got
TypeError: res.setPreviewData is not a function
and thereq
value is{}
.Now I have to use both custom server and enable
useFileSystemPublicRoutes
. Did I miss anything?Beta Was this translation helpful? Give feedback.
All reactions