UNPKG

@ordojs/cli

Version:

Command-line interface for OrdoJS framework

115 lines 3.17 kB
/** * @fileoverview OrdoJS CLI - Vercel deployment adapter * Adapter for deploying to Vercel */ import { OptimizationResults } from '../../asset-optimizer.js'; import { DeploymentAdapter, DeploymentConfig, DeploymentResult } from '../adapter-interface.js'; /** * Vercel-specific configuration */ export interface VercelConfig extends DeploymentConfig { /** * Vercel project settings */ settings?: { /** * Vercel project name */ projectName?: string; /** * Vercel framework preset */ framework?: string; /** * Vercel region */ region?: string; /** * Node.js version */ nodeVersion?: string; /** * Whether to use Edge Functions */ useEdgeFunctions?: boolean; /** * Whether to use Vercel Analytics */ analytics?: boolean; /** * Whether to use Vercel Image Optimization */ imageOptimization?: boolean; }; } /** * Vercel deployment adapter */ export declare class VercelAdapter implements DeploymentAdapter { /** * Adapter name */ name: string; /** * Adapter description */ description: string; /** * Validate Vercel deployment configuration * @param config Deployment configuration * @returns Validation result */ validateConfig(config: DeploymentConfig): { valid: boolean; errors?: string[]; }; /** * Prepare Vercel deployment * @param config Deployment configuration * @returns Deployment result */ prepareDeployment(config: DeploymentConfig): Promise<DeploymentResult>; /** * Generate Vercel configuration * @param config Vercel configuration * @returns Vercel configuration JSON */ private generateVercelConfig; /** * Generate Vercel project configuration * @param config Vercel configuration * @returns Project configuration JSON */ private generateProjectConfig; /** * Generate server functions for Vercel * @param config Deployment configuration */ private generateServerFunctions; /** * Get deployment instructions * @param config Vercel configuration * @returns Deployment instructions */ private getDeploymentInstructions; /** * Optimize assets for Vercel deployment * @param config Deployment configuration * @param outputDir Output directory * @returns Optimization results */ optimizeForDeployment(config: DeploymentConfig, outputDir: string): Promise<OptimizationResults>; /** * Get Vercel-specific environment variables * @param config Deployment configuration * @returns Environment variables */ getEnvironmentVariables(config: DeploymentConfig): Record<string, string>; /** * Get Vercel deployment command * @param config Deployment configuration * @returns Deployment command */ getDeployCommand(config: DeploymentConfig): string; } //# sourceMappingURL=vercel-adapter.d.ts.map