TypeScript indexer plugin for CodeMap (https://github.com/qxbyte/codemap)
Project description
codemap-typescript
A TypeScript / TSX indexer for CodeMap, distributed as an independent PyPI package.
What this package proves
Adding a new language to CodeMap doesn't require touching the main
repository. This package implements the codemap.indexers.base.Indexer
Protocol against *.ts / *.tsx files and registers through the
codemap.indexers entry-point group. Once installed it appears in
codemap doctor next to the built-in indexers, on completely equal
footing (ADR-004 + ADR-L001).
$ pip install codemap-typescript
$ codemap doctor
Registered indexers
┏━━━━━━━━━━━━━━━┳━━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━━━━━━┓
┃ name ┃ version ┃ languages ┃ file_patterns ┃
┡━━━━━━━━━━━━━━━╇━━━━━━━━━╇━━━━━━━━━━━━╇━━━━━━━━━━━━━━━┩
│ _example_lang │ 0.1.0 │ example │ *.example │
│ python │ 0.1.0 │ python │ *.py, *.pyi │
│ typescript │ 0.1.0 │ typescript │ *.ts, *.tsx │
└───────────────┴─────────┴────────────┴───────────────┘
codemap.indexers.disabled: ["typescript"] in .codemap/config.yaml turns
it off without uninstalling.
What it captures
Backed by tree-sitter-typescript. Single-file, no cross-file type
inference (MVP):
| AST node | Symbol kind | SymbolID descriptor |
|---|---|---|
function_declaration |
function |
<path>/name(). |
class_declaration |
class |
<path>/Cls# |
interface_declaration |
interface |
<path>/Cls# |
method_definition (inside class) |
method |
<path>/Cls#name(). |
lexical_declaration (top-level const/let) |
variable |
<path>/Name. |
Edges:
import_statement/import_from_clause→importsto a synthetic module symbol (consumed by the same bridges the Python indexer drives).
The matcher is intentionally lean — class inheritance, generic constraints, and decorators are not yet captured. The point is that they can be: a v0.2.0 PR to this repository is enough to extend coverage, the main CodeMap repository stays untouched.
SymbolID encoding
scip-typescript . . . src/app/Service.ts/UserService#login().
└──────────────┘ └──────────────────────────────────┘
scheme file → namespaces / type / method
Tests
pip install -e ".[dev]"
pytest
Limits / next steps
- No cross-file
importresolution. The mainpython_cross_modulebridge has a sibling for Python; atypescript_cross_modulebridge could be added in a future release. - No JSX-specific patterns (component declarations) yet.
interface_declarationis captured asclasskind — CodeMap's symbol schema doesn't yet have a distinctinterfacekind, see design §3.3.
License
MIT — same as the host project.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file codemap_typescript-0.4.2.tar.gz.
File metadata
- Download URL: codemap_typescript-0.4.2.tar.gz
- Upload date:
- Size: 6.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5705dc64fd7006da0c07e57046f9ad61a5f019eec2a802ec98eee419f07aa715
|
|
| MD5 |
3cd1f99a40ce8374a894120c73f08817
|
|
| BLAKE2b-256 |
4f97b3bf42f75d5e124a811dbfba0bfef830092aed02aa5a0627c16b3cbc5c09
|
Provenance
The following attestation bundles were made for codemap_typescript-0.4.2.tar.gz:
Publisher:
publish.yml on qxbyte/codemap
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
codemap_typescript-0.4.2.tar.gz -
Subject digest:
5705dc64fd7006da0c07e57046f9ad61a5f019eec2a802ec98eee419f07aa715 - Sigstore transparency entry: 1970729198
- Sigstore integration time:
-
Permalink:
qxbyte/codemap@59236156ec3ae2a9f8e112cc931d42799ad452c8 -
Branch / Tag:
refs/tags/v0.4.2 - Owner: https://github.com/qxbyte
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@59236156ec3ae2a9f8e112cc931d42799ad452c8 -
Trigger Event:
push
-
Statement type:
File details
Details for the file codemap_typescript-0.4.2-py3-none-any.whl.
File metadata
- Download URL: codemap_typescript-0.4.2-py3-none-any.whl
- Upload date:
- Size: 6.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8a38797d8fcb9b547bce8a67720442798f34c0963507a26988b05f6cf88200e9
|
|
| MD5 |
da488d5b3f032e7dbf860793b4e4b887
|
|
| BLAKE2b-256 |
7b7b520d2358aec0f49b1143112df43e565da48a48eaadb56abb5e3f81b41305
|
Provenance
The following attestation bundles were made for codemap_typescript-0.4.2-py3-none-any.whl:
Publisher:
publish.yml on qxbyte/codemap
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
codemap_typescript-0.4.2-py3-none-any.whl -
Subject digest:
8a38797d8fcb9b547bce8a67720442798f34c0963507a26988b05f6cf88200e9 - Sigstore transparency entry: 1970729328
- Sigstore integration time:
-
Permalink:
qxbyte/codemap@59236156ec3ae2a9f8e112cc931d42799ad452c8 -
Branch / Tag:
refs/tags/v0.4.2 - Owner: https://github.com/qxbyte
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@59236156ec3ae2a9f8e112cc931d42799ad452c8 -
Trigger Event:
push
-
Statement type: