Skip to main content
StartupSnapshot.setDeserializeMainFunction - v8 - Node documentation
method StartupSnapshot.setDeserializeMainFunction

Usage in Deno

import { type StartupSnapshot } from "node:v8";
StartupSnapshot.setDeserializeMainFunction(
data?: any,
): void

This sets the entry point of the Node.js application when it is deserialized from a snapshot. This can be called only once in the snapshot building script. If called, the deserialized application no longer needs an additional entry point script to start up and will simply invoke the callback along with the deserialized data (if provided), otherwise an entry point script still needs to be provided to the deserialized application.

Parameters

optional
data: any

Return Type

void
Back to top