UNPKG

@dscodotco/theme-cli

Version:

A CLI tool for developing Shopify themes

36 lines (35 loc) 986 B
import Shopify from "shopify-api-node"; import { ThemeManager } from "./theme-manager.js"; export interface ThemePage { path: string; template: string; type: "static" | "collections" | "pages" | "blogs" | "products" | "collections"; title: string; } export interface ThemeMetadata { pages: ThemePage[]; templates: { [key: string]: { path: string; sections: string[]; snippets: string[]; }; }; assets: string[]; config: { settings_schema: any; settings_data: any; }; } export declare class ThemeAPI { private shopify; private themeManager; private themeDir; private metadata; constructor(shopify: Shopify, themeManager: ThemeManager, themeDir: string); getPages(): Promise<ThemePage[]>; private getStaticTemplates; getMetadata(): Promise<ThemeMetadata>; getPageMetadata(path: string): Promise<ThemePage | null>; invalidateCache(): void; }