Skip to main content
API Reference / @modelence/next / NextServer Defined in: index.ts:11 Next.js server implementation for Modelence applications. This class wraps Next.js to provide a compatible server interface for the Modelence framework.

Implements

  • AppServer

Constructors

Constructor

new NextServer(): NextServer

Returns

NextServer

Methods

handler()

handler(req, res): void
Defined in: index.ts:30 Handle incoming HTTP requests using Next.js.

Parameters

ParameterTypeDescription
reqRequestExpress request object
resResponseExpress response object

Returns

void

Implementation of

AppServer.handler

init()

init(): Promise<void>
Defined in: index.ts:17 Initialize the Next.js application and prepare the request handler.

Returns

Promise<void>

Implementation of

AppServer.init