codemap-javascript
A JavaScript / JSX indexer for CodeMap, distributed as an independent PyPI package.
What this package covers
| Extension | Grammar | Notes |
|---|---|---|
.js |
tree-sitter-javascript |
Plain JavaScript |
.jsx |
tree-sitter-javascript |
React-style JSX (the grammar handles JSX natively) |
.mjs |
tree-sitter-javascript |
ES module |
.cjs |
tree-sitter-javascript |
CommonJS module |
A single grammar instance handles all four extensions — .jsx is not
a separate grammar in tree-sitter-javascript.
Install
pip install codemap-javascript
After installation, codemap doctor lists javascript alongside the
built-in indexers (ADR-004 + ADR-L001).
What it captures
Backed by tree-sitter-javascript. Single-file, no cross-file resolution:
| AST node | Symbol kind | SymbolID descriptor |
|---|---|---|
function_declaration |
function |
<path>/name(). |
class_declaration |
class |
<path>/Cls# |
method_definition (inside class) |
method |
<path>/Cls#name(). |
Top-level const / let / var |
variable |
<path>/Name. |
Edges:
import_statementis read for future cross-module bridge consumption, but no edge is emitted at the module top-level (parity with the TypeScript plugin).
SymbolID encoding
scip-javascript . . . src/app/Service.js/UserService#login().
└─────────────┘ └──────────────────────────────────────┘
scheme file → namespaces / type / method
Why a separate plugin (vs. extending codemap-typescript)
TypeScript is a syntactic superset of JavaScript, so tree-sitter-typescript
can parse most .js / .jsx files. We ship a dedicated plugin instead
for three reasons:
- Clean dependency:
codemap-javascriptdoes not depend ontree-sitter-typescript. Users who only have JavaScript code do not need the larger grammar. - JS-specific error recovery: when a
.jsfile has a syntax error, the JavaScript grammar's error nodes point at JS-shaped tokens rather than TS-shaped ones, which produces tighter diagnostics. - Independent versioning: JS language updates (decorators, class
fields, RegExp
vflag) can ship at their own cadence without bumping the TypeScript plugin.
For pure type-extraction purposes the two plugins produce equivalent
symbol output for .js / .jsx files. Install whichever matches your
codebase; install both if you have a mixed code-base.
Tests
pip install -e ".[dev]"
pytest
Limits / next steps
- No cross-file
importresolution. Ajavascript_cross_modulebridge, sibling topython_cross_module, would be a future addition. - Arrow functions assigned to top-level
constare indexed asvariable, notfunction— matching the TypeScript plugin. Named arrow detection across both plugins is a v0.2.x improvement. - JSX-specific component patterns are not yet captured beyond the underlying function/class symbols.
License
MIT — same as the host project.
Metadata
Release files for codemap-javascript 0.4.10
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| codemap_javascript-0.4.10.tar.gz | 6.8 kB | With provenance | Details for codemap_javascript-0.4.10.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| codemap_javascript-0.4.10-py3-none-any.whl | Python 3 | none | any | Details for codemap_javascript-0.4.10-py3-none-any.whl |
Total release size: 13.1 kB
Release files / codemap_javascript-0.4.10.tar.gz
| Download URL | codemap_javascript-0.4.10.tar.gz |
|---|---|
| Size | 6.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3527a91580b318913f2955894d2e9ad0760f65ad4c52c4f55a28accccbe9c5f4
|
|
BLAKE2b-256 checksum How to use checksums |
cc8d991e2ca13b0bdaaa28ad0b62dbb216813f6ef6505cc32dbfca8b1101ec59
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 17, 2026.
Transparency logRelease files / codemap_javascript-0.4.10-py3-none-any.whl
| Download URL | codemap_javascript-0.4.10-py3-none-any.whl |
|---|---|
| Size | 6.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
552137d3d82da1b24eb120dc4d37dcedd017a887c72ca3345921dd6b086e06dd
|
|
BLAKE2b-256 checksum How to use checksums |
a3c58fcc3f0d074103121e3a94173aba256c3d039793327dfe7874f77000e6e9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 17, 2026.
Transparency logSecurity for codemap-javascript 0.4.10
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for codemap_javascript-0.4.10.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 17, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.