export interface GuiBuildOptions { /** * module paths you want to compile with hanzogui (for example ['hanzogui']) * */ components?: string[]; /** * relative path to your hanzogui.config.ts */ config?: string; /** * Use the new ThemeBuilder in `@hanzogui/create-theme` to create beautiful theme sets, * see docs at https://hanzogui.dev/docs/guides/theme-builder * This helps you automate generating the build themes typescript file which loads fastere * and has smaller bundle size. */ themeBuilder?: { input: string; output: string; }; /** * Emit design system related CSS during build step for usage with frameworks */ outputCSS?: string | null | false; /** * (Experimental) outputs themes using CSS Nesting https://caniuse.com/css-nesting * Which can cut them in half due to no media query duplication. */ useCSSNesting?: boolean; /** * Gui can follow imports and evaluate them when parsing styles, leading to * higher percent of flattened / optimized views. We normalize this to be the * full path of the file, always ending in ".js". * * So to have Gui partially evaluate "app/src/constants.tsx" you can put * ["app/src/constants.js"]. */ importsWhitelist?: string[]; /** * Installed packages whose styles the compiler extracts statically. A file * under `node_modules` is only read if its package is named here — matching * a whole scope with `@scope/*`, or one package exactly. The compiler cannot * afford to parse every installed JS file, so nothing is read by default. * * `DEFAULT_EXTRACT_PACKAGES` from `@hanzogui/static-worker` is the * design-system list (`@hanzo/ui`, `@hanzo/gui`, `@hanzogui/*`). Read its * doc comment before turning it on: today it grows the cached sheet without * shrinking what the runtime injects, because a published package ships no * JSX to flatten. * * @default [] */ extractPackages?: string[]; /** * Whitelist file extensions to evaluate * * @default ['.tsx', '.jsx'] */ includeExtensions?: string[]; /** * Web-only. Allows you to trim the bundle size of react-native-web. * Pass in values like ['Switch', 'Modal']. */ excludeReactNativeWebExports?: string[]; /** * Enable logging the time it takes to extract. * * @default true */ logTimings?: boolean; /** * Custom prefix for the timing logs */ prefixLogs?: string; /** * (Advanced) Enables Gui to try and evaluate components outside the `components` option. * When true, Gui will bundle and load components as its running across every file, * if it loads them successfully it will perform all optimiziations inline. */ enableDynamicEvaluation?: boolean; /** * Completely disable hanzogui for these files */ disable?: boolean | string[]; /** * Disable just optimization for these files, but enable helpful debug attributes. */ disableExtraction?: boolean | string[]; /** * Disable just the addition of data- attributes that are added in dev mode to help * tie DOM to your filename/component-name. */ disableDebugAttr?: boolean; /** * (Advanced) Disable evaluation of useMedia() hook */ disableExtractInlineMedia?: boolean; /** * (Advanced) Disable just view flattening. */ disableFlattening?: boolean; /** * (Advanced) Disable extracting to theme variables. */ disableExtractVariables?: boolean | 'theme'; /** * (Advanced) Disables the initial build and attempts to load from the .hanzogui directory */ disableInitialBuild?: boolean; /** * If you have a hanzogui.build.ts file that describes your compiler setup, you can set it here */ buildFile?: string; evaluateVars?: boolean; cssPath?: string; cssData?: any; deoptProps?: Set; excludeProps?: Set; inlineProps?: Set; /** * Use react-native-web-lite for better tree shaking on web. * Set to 'without-animated' to exclude animated components. */ useReactNativeWebLite?: boolean | 'without-animated'; disableWatchGuiConfig?: boolean; /** * (Experimental) Flatten theme access on native for better performance */ experimentalFlattenThemesOnNative?: boolean; } export interface GuiOptions extends GuiBuildOptions { platform?: 'native' | 'web'; } export type CLIUserOptions = { root?: string; host?: string; tsconfigPath?: string; hanzoguiOptions: Partial; debug?: boolean | 'verbose'; loadGuiOptions?: boolean; }; export type CLIResolvedOptions = { root: string; port?: number; host?: string; mode: 'development' | 'production'; debug?: CLIUserOptions['debug']; tsconfigPath: string; hanzoguiOptions: GuiOptions; pkgJson: { name?: string; main?: string; module?: string; source?: string; exports?: Record>; }; paths: { root: string; dotDir: string; conf: string; types: string; }; }; //# sourceMappingURL=index.d.ts.map