Skip to main content

Module analyzer

Module analyzer 

Source
Expand description

Dependency analyzer — scan all JS files, build import graph, and collect analysis results for the transpiler pipeline.

The entry JS file and its transitive dependencies form a single project. Non-entry files can be imported by multiple dependents.

Structs§

AnalysisResult
Analysis result: the entry file + all its transitive dependencies, with parsed ASTs and import/export metadata.

Functions§

analyze_project
Analyze JS root files and their transitive dependencies, returning all data needed for transpilation.
sanitize_module_name
Convert a module name (from filename) to a valid Zig identifier suffix. Non-ASCII characters are converted to Unicode codepoint format _uXXXX.