/** * Node/Bun/Deno executor implementation. * * Executes bundled JavaScript code using temp files and dynamic import. * This provides basic execution without full isolation. * * For isolated execution, consider using Node's vm module or worker threads. */ import type { IExecutor } from "../types"; import { type BasicExecutorOptions } from "../core/executor"; /** * Options for creating a NodeExecutor. */ export type NodeExecutorOptions = BasicExecutorOptions; /** * Executor that runs code in Node.js/Bun/Deno. * * Uses data URLs with dynamic import for execution. * This approach works across Node.js, Bun, and Deno. * * WARNING: This executor provides NO isolation. The executed code has * full access to the process environment, file system, and network. * Only use for trusted code. * * @example * ```ts * const executor = createNodeExecutor(); * const result = await executor.execute(bundledCode, { * entryExport: 'main', * context: { args: ['--verbose'] }, * timeout: 5000, * }); * console.log(result.logs); * ``` */ export declare class NodeExecutor implements IExecutor { private executor; constructor(options?: NodeExecutorOptions); execute: IExecutor["execute"]; } /** * Create a Node executor. * * @param options - Executor options * @returns A new NodeExecutor instance */ export declare function createNodeExecutor(options?: NodeExecutorOptions): NodeExecutor; //# sourceMappingURL=executor.d.ts.map