esbuild-plugin-node-externals
Version:
ESBuild plugin for node externals.
38 lines (34 loc) • 874 B
TypeScript
import { Plugin } from 'esbuild';
interface NodeExternalsOptions {
/**
* list of package.json paths to read from
* if not specified, will read from cwd
*/
packagePaths: string | string[];
/**
* mark all dependencies as external
* @default true
*/
withDeps: boolean;
/**
* mark all devDependencies as external
* @default true
*/
withDevDeps: boolean;
/**
* mark all peerDependencies as external
* @default true
*/
withPeerDeps: boolean;
/**
* mark all optionalDependencies as external
* @default true
*/
withOptDeps: boolean;
/**
* list of packages to exclude from externalization
*/
include: string[];
}
declare const nodeExternals: (options?: Partial<NodeExternalsOptions>) => Plugin;
export { nodeExternals as default, nodeExternals };