Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Annotate ¶
func Annotate(prog *ast.Program, cfg *config.Config, sourceFile string, rawSource string) *irtree.Annotations
Annotate performs static analysis on a parsed program to determine component tiers, signal declarations, streaming mode, and used components.
func MergeModuleFunctions ¶
func MergeModuleFunctions(ann *irtree.Annotations, modules []ModuleSource)
MergeModuleFunctions collects function declarations from additional bundled modules and merges them into the annotations. Imported components (e.g. DocsLayout, SidebarNav) live in separate bundled modules that the entry module's AST doesn't contain. Each module's own source path/raw text is recorded so tier classification for imported components uses their own file conventions (e.g. *.runtime.tsx).
func ReclassifyTiers ¶
func ReclassifyTiers(ann *irtree.Annotations, cfg *config.Config)
ReclassifyTiers re-runs tier classification for all used components. Call after MergeModuleFunctions so newly discovered components get classified against their own module sources.