storybook-addon-stencil
Version:
A Stencil compiler integration for Storybook.
19 lines (18 loc) • 849 B
TypeScript
import type { SourceFile } from "typescript";
import type { Package, CssPart, CssCustomProperty, Slot } from "custom-elements-manifest/schema";
import { ComponentCompilerMeta } from "@stencil/core/internal";
type ComponentMeta = ComponentCompilerMeta & {
cssProperties: CssCustomProperty[];
cssParts: CssPart[];
slots: Slot[];
};
/**
* Convert Stencil data to Custom Elements v1 manifest.
* @see https://github.com/webcomponents/custom-elements-manifest
* @param classDeclaration The resulting Stencil transpiled data.
* @param fileName The file name of the module.
* @returns The manifest.
*/
export declare function generateCustomElementsManifest(classDeclaration: ComponentMeta, fileName: string): Package;
export declare function generateCustomElementDeclaration(classDeclaration: any, sourceFile: SourceFile): any;
export {};