Custom error page for api routes
Unanswered
Polish posted this in #help-forum
PolishOP
In Next.JS v14.2.4 how can you create custom error responses for api routes? For example, for 404 and 405 I want to be able to respond with JSON since it is a api route