# System map — swc-project/swc

> Canonical page: https://codevetter.com/unpack/swc/system-map

# System map — swc-project/swc

Scanned commit 3c46139b86b27a7b3fefcf7b19ca07a63de9db0a (2026-10-02). Generated by codevetter codevetter 1.15.0 on 2026-10-02.

Source inspection; upstream code and tests were not executed.

SWC is organized as a compiler workspace with several embedding boundaries. Rust crates provide compilation and language infrastructure, while Node and WebAssembly bindings expose selected operations to JavaScript consumers. The standalone CLI dispatches through a separate implementation crate, and native package loading includes a verified filesystem cache. Build, test, benchmark, and publication workflows are separate operational surfaces.
- The Cargo workspace includes xtask, bindings, crates, code generation, release tooling, and the native addon packer; shared packages use Rust edition 2021. — [Cargo.toml#L1-15](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/Cargo.toml#L1-L15)
- The compiler layers separate AST definitions, parsing, code generation, and base transforms; resolver distinguishes bindings, hygiene renames conflicting symbols, and fixer restores valid expression structure. — [ARCHITECTURE.md#L34-52](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/ARCHITECTURE.md#L34-L52) [ARCHITECTURE.md#L72-96](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/ARCHITECTURE.md#L72-L96)
- @swc/core exposes a TypeScript Compiler facade backed by native bindings or @swc/wasm; SWC_BINARY_PATH overrides the native module location. — [packages/core/src/index.ts#L21-43](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/packages/core/src/index.ts#L21-L43) [packages/core/src/index.ts#L146-164](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/packages/core/src/index.ts#L146-L164)
- binding_core_node is a cdylib targeting N-API 3; its default features enable swc_v1 bundling and native Wasmer plugins with filesystem caching. — [bindings/binding_core_node/Cargo.toml#L11-23](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/bindings/binding_core_node/Cargo.toml#L11-L23) [bindings/binding_core_node/Cargo.toml#L36-45](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/bindings/binding_core_node/Cargo.toml#L36-L45)
- Compiler owns an Arc<SourceMap> and comments; the Node binding provides both a lazy shared compiler and get_fresh_compiler for isolated source maps. — [crates/swc/src/lib.rs#L406-415](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/crates/swc/src/lib.rs#L406-L415) [bindings/binding_core_node/src/lib.rs#L27-50](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/bindings/binding_core_node/src/lib.rs#L27-L50)
- The standalone executable calls swc_cli_impl::run, which parses Clap options and dispatches plugin-new, compile, minify, bundle, or lint handlers. — [bindings/swc_cli/src/main.rs#L1-3](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/bindings/swc_cli/src/main.rs#L1-L3) [crates/swc_cli_impl/src/lib.rs#L7-16](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/crates/swc_cli_impl/src/lib.rs#L7-L16)
- Development uses pnpm@10.33.3; core build scripts run TypeScript declaration generation and napi build, while package tests invoke Rstest. — [package.json#L1-15](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/package.json#L1-L15) [packages/core/package.json#L52-62](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/packages/core/package.json#L52-L62)
- Distribution includes native npm addons and Rust crates: carrier documentation defines eight compressed targets, while automatic crate publication requires a main-branch commit beginning 'chore: Publish' and obtains crates.io authentication through OIDC. — [docs/native-addon-carriers.md#L3-14](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/docs/native-addon-carriers.md#L3-L14) [.github/workflows/publish-crates.yml#L25-34](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/.github/workflows/publish-crates.yml#L25-L34) [.github/workflows/publish-crates.yml#L61-69](https://github.com/swc-project/swc/blob/3c46139b86b27a7b3fefcf7b19ca07a63de9db0a/.github/workflows/publish-crates.yml#L61-L69)

Every claim links to its cited files at the pinned commit. Citations identify source evidence; they do not establish runtime correctness. Independent CodeVetter scan — not reviewed by upstream maintainers.

## Public product links

- [CodeVetter](https://codevetter.com/)
- [Download](https://codevetter.com/download)
- [Documentation](https://codevetter.com/docs/)
- [Source](https://github.com/Codevetter/codevetter)
