You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: repoint docs base path and links to renamed repo
The repo was renamed codeanalyzer-ts -> codeanalyzer-typescript, but the
Astro base and all hardcoded content links still pointed at the old name,
so GitHub Pages (now served at /codeanalyzer-typescript/) 404'd every
asset — the site rendered unstyled. Update base, site edit links, and the
/codeanalyzer-ts/ content-link prefixes.
Copy file name to clipboardExpand all lines: README.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# codeanalyzer-typescript — documentation site
2
2
3
-
This branch holds the documentation site for [**codeanalyzer-typescript**](https://github.com/codellm-devkit/codeanalyzer-ts), the TypeScript/JavaScript static-analysis backend behind [CLDK](https://github.com/codellm-devkit/python-sdk). The tool's source code lives on `main`; this `docs` branch is the [Astro](https://astro.build/) + [Starlight](https://starlight.astro.build/) site that documents it.
3
+
This branch holds the documentation site for [**codeanalyzer-typescript**](https://github.com/codellm-devkit/codeanalyzer-typescript), the TypeScript/JavaScript static-analysis backend behind [CLDK](https://github.com/codellm-devkit/python-sdk). The tool's source code lives on `main`; this `docs` branch is the [Astro](https://astro.build/) + [Starlight](https://starlight.astro.build/) site that documents it.
4
4
5
5
## Develop
6
6
@@ -36,22 +36,22 @@ astro.config.mjs # site + sidebar config
36
36
37
37
## Internal links (important)
38
38
39
-
The site is served from a **base path** — `https://codellm-devkit.github.io/codeanalyzer-ts/` (set via `site` + `base` in `astro.config.mjs`). Astro does **not** rewrite links in page content, so every internal link must include the base prefix:
39
+
The site is served from a **base path** — `https://codellm-devkit.github.io/codeanalyzer-typescript/` (set via `site` + `base` in `astro.config.mjs`). Astro does **not** rewrite links in page content, so every internal link must include the base prefix:
Sidebar `slug` entries in `astro.config.mjs` and assets are based automatically — only authored links in `.mdx` need the prefix. To verify after editing, build and grep `dist/` for any `href="/…"` that doesn't start with `/codeanalyzer-ts/`.
50
+
Sidebar `slug` entries in `astro.config.mjs` and assets are based automatically — only authored links in `.mdx` need the prefix. To verify after editing, build and grep `dist/` for any `href="/…"` that doesn't start with `/codeanalyzer-typescript/`.
51
51
52
52
## Deploy
53
53
54
-
Pushing to `docs` triggers `.github/workflows/deploy.yml`, which builds the site and publishes `dist/` to the `gh-pages` branch. GitHub Pages then serves it at `https://codellm-devkit.github.io/codeanalyzer-ts/`.
54
+
Pushing to `docs` triggers `.github/workflows/deploy.yml`, which builds the site and publishes `dist/` to the `gh-pages` branch. GitHub Pages then serves it at `https://codellm-devkit.github.io/codeanalyzer-typescript/`.
The call graph is the answer to *"who calls whom?"* — a flat list of identity-only `TSCallEdge` objects whose `source` and `target` are signature strings. This page is the deep dive on how the **level-1** graph is built: the TypeScript checker resolves each recorded call site, Rapid Type Analysis expands virtual dispatch, and phantom nodes capture the calls that leave the project. It's the always-on base graph; [level 2](/codeanalyzer-ts/guides/level-2/) enriches it.
8
+
The call graph is the answer to *"who calls whom?"* — a flat list of identity-only `TSCallEdge` objects whose `source` and `target` are signature strings. This page is the deep dive on how the **level-1** graph is built: the TypeScript checker resolves each recorded call site, Rapid Type Analysis expands virtual dispatch, and phantom nodes capture the calls that leave the project. It's the always-on base graph; [level 2](/codeanalyzer-typescript/guides/level-2/) enriches it.
9
9
10
10
```mermaid
11
11
flowchart TB
@@ -88,7 +88,7 @@ The edge into it carries `provenance: ["import"]`, and the phantom is recorded i
88
88
A specifier is external only if it isn't a relative or absolute path. Packages (`express`), scoped packages (`@scope/pkg`), and `node:` URLs become phantoms; relative imports (`./x`, `../lib/y`) are internal and left to the checker, never faked. Phantom resolution reads only imports — no type checker, no `node_modules` — so it works identically for TypeScript `import` and JavaScript `require`.
89
89
</Aside>
90
90
91
-
Disable phantom resolution entirely with [`--no-phantoms`](/codeanalyzer-ts/guides/cli-usage/#phantom-nodes) if you want a graph restricted to in-project targets.
91
+
Disable phantom resolution entirely with [`--no-phantoms`](/codeanalyzer-typescript/guides/cli-usage/#phantom-nodes) if you want a graph restricted to in-project targets.
92
92
93
93
## Why identity-only edges
94
94
@@ -109,8 +109,8 @@ exact = [(u, v) for u, v, d in g.edges(data=True) if not d["rta"]]
109
109
## Where to go next
110
110
111
111
<CardGrid>
112
-
<LinkCardtitle="Core concepts"description="How the call graph sits alongside the symbol table and external symbols."href="/codeanalyzer-ts/guides/concepts/" />
113
-
<LinkCardtitle="Output schema"description="The TSCallEdge and TSExternalSymbol models in full."href="/codeanalyzer-ts/reference/schema/#tscalledge" />
114
-
<LinkCardtitle="Level 2: CodeQL & entrypoints"description="What enrichment will add on top of this graph."href="/codeanalyzer-ts/guides/level-2/" />
115
-
<LinkCardtitle="CLI usage"description="Flags that change the graph: analysis level, phantoms."href="/codeanalyzer-ts/guides/cli-usage/" />
112
+
<LinkCardtitle="Core concepts"description="How the call graph sits alongside the symbol table and external symbols."href="/codeanalyzer-typescript/guides/concepts/" />
113
+
<LinkCardtitle="Output schema"description="The TSCallEdge and TSExternalSymbol models in full."href="/codeanalyzer-typescript/reference/schema/#tscalledge" />
114
+
<LinkCardtitle="Level 2: CodeQL & entrypoints"description="What enrichment will add on top of this graph."href="/codeanalyzer-typescript/guides/level-2/" />
115
+
<LinkCardtitle="CLI usage"description="Flags that change the graph: analysis level, phantoms."href="/codeanalyzer-typescript/guides/cli-usage/" />
The `codeanalyzer-typescript` command runs static analysis on a TypeScript/JavaScript project and emits a `TSApplication` artifact. This guide walks through the common invocations; for the full flag table see the [CLI reference](/codeanalyzer-ts/reference/cli/).
8
+
The `codeanalyzer-typescript` command runs static analysis on a TypeScript/JavaScript project and emits a `TSApplication` artifact. This guide walks through the common invocations; for the full flag table see the [CLI reference](/codeanalyzer-typescript/reference/cli/).
9
9
10
10
<Asidetype="note"title="Invoking the analyzer">
11
11
The examples below call the compiled binary `codeanalyzer-typescript`. If you haven't built it, run from source instead — `bun run start -- --input …` — everything after `--` is identical.
Every run produces a symbol table **and** a call graph. At level 1, edges come from the TypeScript checker plus Rapid Type Analysis, with phantom nodes for calls into imported libraries. Level 2 is intended to merge in CodeQL-derived edges.
57
57
58
58
<Asidetype="caution">
59
-
Level-2 CodeQL enrichment is **experimental** and currently a stub: it logs a warning and emits no extra edges, falling back to the level-1 graph. See [Level 2: CodeQL & entrypoints](/codeanalyzer-ts/guides/level-2/).
59
+
Level-2 CodeQL enrichment is **experimental** and currently a stub: it logs a warning and emits no extra edges, falling back to the level-1 graph. See [Level 2: CodeQL & entrypoints](/codeanalyzer-typescript/guides/level-2/).
Materialization runs the project's package manager with `--ignore-scripts` and **degrades gracefully**: if the install fails, the run still completes with partial type information. See [Installation](/codeanalyzer-ts/installing/#why-your-project-needs-its-dependencies).
74
+
Materialization runs the project's package manager with `--ignore-scripts` and **degrades gracefully**: if the install fails, the run still completes with partial type information. See [Installation](/codeanalyzer-typescript/installing/#why-your-project-needs-its-dependencies).
75
75
76
76
## Caching: eager vs lazy
77
77
@@ -117,7 +117,7 @@ By default, calls into imported libraries become phantom `external_symbols` so t
Copy file name to clipboardExpand all lines: src/content/docs/guides/concepts.mdx
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,7 +40,7 @@ flowchart LR
40
40
41
41
A `TSCallable` (function, method, constructor, accessor, or arrow) carries its `signature`, source `code`, `parameters`, `type_parameters`, `decorators`, `call_sites`, accessed symbols, cyclomatic complexity, and TypeScript-native flags (`is_async`, `is_static`, `is_abstract`, `accessibility`, …). A `TSClass` carries its `base_classes`, `implements_types`, `methods`, `attributes`, and decorators. The TypeScript node kinds Python and Java don't have — interfaces, enums, type aliases, namespaces — are first-class. Each node records line/column spans so you can map any element back to source.
42
42
43
-
Construction is done by the **TypeScript compiler** through [ts-morph](https://ts-morph.com/): the same checker that types the project resolves references, so the analyzer materializes the project's `node_modules` first (see [Installation](/codeanalyzer-ts/installing/)).
43
+
Construction is done by the **TypeScript compiler** through [ts-morph](https://ts-morph.com/): the same checker that types the project resolves references, so the analyzer materializes the project's `node_modules` first (see [Installation](/codeanalyzer-typescript/installing/)).
44
44
45
45
<Asidetype="note"title="Signatures are the identity">
46
46
A callable's `signature` (e.g. `src/user.UserService.getUser`) is its identity across the whole artifact. Call-graph edges and entrypoints both reference callables by signature, not by a separate node object — see [below](#signatures-are-the-identity).
@@ -58,7 +58,7 @@ flowchart LR
58
58
B -->|import| E["node:fs.readFileSync"]
59
59
```
60
60
61
-
The TypeScript checker resolves each recorded call site to a callee declaration and backfills `callee_signature` in place; the resulting edges are guaranteed to point at real signatures (no dangling edges). Virtual dispatch is expanded with **Rapid Type Analysis**, and calls leaving the project become phantom **external symbols**. The full mechanism is its own page — [Call graph & dispatch](/codeanalyzer-ts/guides/call-graph/).
61
+
The TypeScript checker resolves each recorded call site to a callee declaration and backfills `callee_signature` in place; the resulting edges are guaranteed to point at real signatures (no dangling edges). Virtual dispatch is expanded with **Rapid Type Analysis**, and calls leaving the project become phantom **external symbols**. The full mechanism is its own page — [Call graph & dispatch](/codeanalyzer-typescript/guides/call-graph/).
62
62
63
63
Because it's a plain edge list keyed by signature, loading it into a graph is direct:
64
64
@@ -92,7 +92,7 @@ Only **bare** specifiers become phantoms — packages like `express`, scoped pac
92
92
**Entrypoints** are the framework-dispatched roots of an application — the functions a framework calls that your own code never calls directly: an HTTP route handler, a message consumer, a CLI command. They're collected into `entrypoints`, keyed by framework name, with each `TSEntrypoint` referencing a callable by signature and carrying framework metadata (route path, HTTP methods, …).
93
93
94
94
<Asidetype="caution"title="Empty at level 1">
95
-
At level 1, `entrypoints` is always `{}`. Framework entrypoint detection is part of the **level-2** roadmap — see [Level 2: CodeQL & entrypoints](/codeanalyzer-ts/guides/level-2/).
95
+
At level 1, `entrypoints` is always `{}`. Framework entrypoint detection is part of the **level-2** roadmap — see [Level 2: CodeQL & entrypoints](/codeanalyzer-typescript/guides/level-2/).
96
96
</Aside>
97
97
98
98
## Signatures are the identity
@@ -126,8 +126,8 @@ flowchart LR
126
126
## Where to go next
127
127
128
128
<CardGrid>
129
-
<LinkCardtitle="Call graph & dispatch"description="The tsc resolver, RTA expansion, and phantom nodes in depth."href="/codeanalyzer-ts/guides/call-graph/" />
130
-
<LinkCardtitle="Output schema"description="Every field of every model in the artifact."href="/codeanalyzer-ts/reference/schema/" />
131
-
<LinkCardtitle="CLI usage"description="The flags that control what ends up in the artifact."href="/codeanalyzer-ts/guides/cli-usage/" />
132
-
<LinkCardtitle="Level 2: CodeQL & entrypoints"description="What the experimental second layer will add."href="/codeanalyzer-ts/guides/level-2/" />
129
+
<LinkCardtitle="Call graph & dispatch"description="The tsc resolver, RTA expansion, and phantom nodes in depth."href="/codeanalyzer-typescript/guides/call-graph/" />
130
+
<LinkCardtitle="Output schema"description="Every field of every model in the artifact."href="/codeanalyzer-typescript/reference/schema/" />
131
+
<LinkCardtitle="CLI usage"description="The flags that control what ends up in the artifact."href="/codeanalyzer-typescript/guides/cli-usage/" />
132
+
<LinkCardtitle="Level 2: CodeQL & entrypoints"description="What the experimental second layer will add."href="/codeanalyzer-typescript/guides/level-2/" />
<LinkCardtitle="Output schema"description="The TSEntrypoint and TSCallEdge models."href="/codeanalyzer-ts/reference/schema/#tsentrypoint" />
83
-
<LinkCardtitle="Core concepts"description="Provenance and how merged edges record their engines."href="/codeanalyzer-ts/guides/concepts/#provenance" />
<LinkCardtitle="Output schema"description="The TSEntrypoint and TSCallEdge models."href="/codeanalyzer-typescript/reference/schema/#tsentrypoint" />
83
+
<LinkCardtitle="Core concepts"description="Provenance and how merged edges record their engines."href="/codeanalyzer-typescript/guides/concepts/#provenance" />
0 commit comments