UNPKG

@pulzar/core

Version:

Next-generation Node.js framework for ultra-fast web applications with zero-reflection DI, GraphQL, WebSockets, events, and edge runtime support

69 lines 2.32 kB
import { Plugin } from "vite"; export interface ViteEdgeOptions { platform?: "cloudflare" | "vercel" | "deno" | "netlify"; entry?: string; output?: string; minify?: boolean; sourcemap?: boolean; external?: string[]; define?: Record<string, string>; target?: string; polyfills?: boolean; frameworkName?: string; outDir?: string; ssr?: boolean; } declare const DEFAULT_NODE_EXTERNALS: string[]; declare const PLATFORM_CONFIGS: { readonly cloudflare: { readonly target: "es2022"; readonly format: "es"; readonly nodeCompat: false; readonly maxSize: number; readonly supportedAPIs: readonly ["fetch", "WebSocket", "crypto", "streams"]; }; readonly vercel: { readonly target: "es2020"; readonly format: "es"; readonly nodeCompat: true; readonly maxSize: number; readonly supportedAPIs: readonly ["fetch", "crypto", "streams"]; }; readonly deno: { readonly target: "es2022"; readonly format: "es"; readonly nodeCompat: true; readonly maxSize: number; readonly supportedAPIs: readonly ["fetch", "WebSocket", "crypto", "streams"]; }; readonly netlify: { readonly target: "es2020"; readonly format: "es"; readonly nodeCompat: true; readonly maxSize: number; readonly supportedAPIs: readonly ["fetch", "crypto", "streams"]; }; }; export declare function edgePlugin(options?: ViteEdgeOptions): Plugin; declare function getPlatformPolyfills(platform: string, frameworkName: string): string; declare function getPlatformWrapper(platform: string, entryFile: string, frameworkName: string): string; export declare function createEdgeConfig(options?: ViteEdgeOptions): { plugins: Plugin<any>[]; build: { target: string; minify: boolean; sourcemap: boolean; ssr: boolean; rollupOptions: { external: string[]; }; }; define: { "process.env.NODE_ENV": string; "process.env.PLATFORM": string; "process.env.FRAMEWORK": string; global: string; }; }; export { DEFAULT_NODE_EXTERNALS, PLATFORM_CONFIGS, getPlatformPolyfills, getPlatformWrapper, }; //# sourceMappingURL=vite-adapter.d.ts.map