Expand description
Component registry: loads and merges all components.jsonld files.
See the components module doc for the two-phase loading overview.
§Span extraction
Every file is parsed with rdf_parsers::jsonld::convert::parse_json before any processing,
which yields a JsonLdVal tree carrying byte-range spans for every token.
collect_id_spans walks the tree and records expanded_iri → byte_range in a flat map.
These spans are threaded through both collection phases so that every
CjsModule,
CjsComponent, and
CjsParameter ends up with an iri_span that
the LSP can use for goto-definition without re-reading the source file.
Structs§
- Component
Registry - Registry of all discovered CJS components and modules.
Functions§
- collect_
id_ sources - Walk a
JsonLdValtree and record the source file for every@idvalue (first-seen wins, consistent withcollect_id_spans). - collect_
id_ spans - Walk a
JsonLdValtree and collect the byte spans of every@idvalue, keyed by the expanded IRI (resolved viaresolver). - resolve_
iri_ to_ url - Resolve an IRI to a local file URL using the import_paths mapping.