zp-figma-converter
Version:
Convert Figma designs to various code formats
35 lines • 1.23 kB
TypeScript
/**
* Main module for the JSON2CSD library.
* Should use the CLI tool: npm run cli
*
* Example:
* - Convert all files: npm run cli convert-all
* - Convert a file: npm run cli convert json/filename.json
* - Convert from Figma: npm run cli convert-figma <fileKey> [nodeId]
* - Show help: npm run cli help
*/
/**
* Figma Code Converter
* Convert Figma designs to various code formats
*/
import { FigmaConverter } from './figma/figma-converter';
import { IntermediateNode } from './figma/intermediate';
import { CsdConverter } from './converters/csd/csd-converter';
export { FigmaConverter };
export { IntermediateNode };
export { CsdConverter };
/**
* Convert Figma node to code
* @param fileKey Figma file key
* @param nodeId Figma node ID (optional)
* @param format Output format (default: csd)
* @param outputPath Output file path (optional)
* @returns Path to the generated file
*/
export declare function convertFigmaToCode(apiKey: string, fileKey: string, nodeId?: string, format?: string, outputPath?: string): Promise<string>;
declare const _default: {
FigmaConverter: typeof FigmaConverter;
convertFigmaToCode: typeof convertFigmaToCode;
};
export default _default;
//# sourceMappingURL=index.d.ts.map