Expand description
Module extraction types: exports, imports, re-exports, and member info. Module extraction types.
Structs§
- Angular
Component Selector - A declared Angular
@Componentand itsselectorvalue(s), harvested from a@Component({ selector: '...' })decorator. Consumed by the Angular arm of theunrendered-componentdetector, which flags a component whose every element selector is used in NO template project-wide (and that is not referenced by class name anywhere, e.g. routed / bootstrapped / dynamically rendered). A multi-selector string ('app-foo, [appBar]') is split into theselectorslist. The span is stored as a byte offset (not anoxc_span::Span) so the type round-trips through the bitcode cache directly, mirroringAngularInputMember::span_start.@Directiveis intentionally NOT harvested here (directives have no template render).ModuleInfois not serialized, so no serde attrs are derived. - Angular
Input Member - A declared Angular component/directive input, harvested from an
@Input()decorator or a signalinput()/input.required()/model()initializer on an Angular-decorated class. Consumed by theunused-component-inputdetector, which flags an input read nowhere in its own component (neither the template nor the class body). The span is stored as a byte offset (not anoxc_span::Span) so the type is cheap to mirror onto the cache, matchingComponentEmit::span_start.ModuleInfois not serialized, so no serde attrs are derived here.bitcodederives let the type be mirrored directly ontoCachedModule(the same pattern asComponentEmit). - Angular
Output Member - A declared Angular component/directive output, harvested from an
@Output()decorator or a signaloutput()/outputFromObservable()initializer on an Angular-decorated class. Consumed by theunused-component-outputdetector, which flags an output emitted nowhere in its own component. Amodel()is an input and a framework-driven output, so it is recorded ONLY as an input and never appears here (the implicitupdate:emit is framework-managed). The span is a byte offset for the same reason asAngularInputMember. - Callee
Use - A statically flattenable callee path invoked in a module (e.g.
execSync,child_process.exec,console.log). One entry per uniquecallee_pathper module; the span anchors the first occurrence. Consumed by theboundaries.calls.forbiddendetector. - Class
Heritage Info - Additional heritage metadata for an exported class.
- Complexity
Contribution - A single complexity increment, located at its source line/column.
- Component
Emit - A Vue
<script setup>defineEmitsdeclared event, harvested from the type tuple-call form (defineEmits<{ (e: 'foo'): void }>()), the type object form (defineEmits<{ foo: [x: string] }>()), or the runtime array form (defineEmits(['foo'])).usedis set during extraction when the bound emit name is called asemit('<name>'). Theunused-component-emitdetector flags an event whereusedis false. Seeharvest_define_emitsinsfc_props.rs. - Component
Function - An identified React component: a function/arrow whose body returns JSX.
Captured by
visit_jsx_element’s enclosing-component tracking. Theunused-component-prop(React arm) and complexity-fold phases consume this; the abstain flags keep zero-FP on the cases ADR-001 cannot resolve. - Component
Prop - A Vue
<script setup>definePropsdeclared prop, harvested from the runtime object form (defineProps({ foo: {...} })) or the inline TS literal form (defineProps<{ foo: T }>()).used_in_script/used_in_templateare set during extraction; theunused-component-propdetector flags a prop where neither is true. Seeharvest_define_propsinsfc.rs. - CssAnalytics
- Stylesheet-level structural CSS analytics, computed from the parsed CSS
syntax tree. Feeds
fallow healthpenalty weights and located findings, never a standalone CSS score. - CssDeclaration
Block - A style rule’s declaration-block fingerprint and location, for cross-file
duplicate-block detection. Only rules with a meaningful number of
declarations are recorded (small blocks repeat legitimately). Internal
staging only: this is consumed in-process by the health layer to build the
grouped
duplicate_declaration_blocksoutput and is never serialized. - CssRule
Metric - Structural CSS metrics for a single style rule, computed from the parsed CSS
syntax tree. A rule is recorded only when it crosses a structural floor (an
id selector, a complex selector, a
!importantdeclaration, or deep nesting), so the vector stays bounded on normal stylesheets. - DiKey
Site - A Vue
provide/injector SveltesetContext/getContextcall site keyed by an identifier symbol. Thekey_localis resolved at analyze time through the consuming module’s import/export tables to a canonical defining-site export key, so a provide and an inject of the same shared symbol unify even across barrel re-exports. Consumed by theunprovided-injectdetector. - Dispatched
Event - A Svelte custom event dispatched via
dispatch('<name>'), wheredispatchis the binding from aconst dispatch = createEventDispatcher()call. Only literal-first-arg dispatches are recorded; adispatch(<nonLiteral>)setsModuleInfo::has_dynamic_dispatchinstead. Consumed by theunused-svelte-eventdetector, which flags an event dispatched here but listened to nowhere project-wide (the cross-file dead-output direction). The span is a byte offset (not anoxc_span::Span) so the type round-trips through the bitcode cache directly, mirroringComponentEmit::span_start. - Dynamic
Import Info - A dynamic
import()call. - Dynamic
Import Pattern - A dynamic import with a partially resolved pattern.
- Export
Info - An export declaration.
- FlagUse
- A feature flag use site.
- Forward
Attr - One forwarded JSX attribute: the child attribute name plus the identifier
root of its value expression. See
RenderEdge::forward_attrs. - Function
Complexity - Complexity metrics for a single function/method/arrow.
- HookUse
- A React hook call site inside a component. Consumed by the complexity-fold phase (hook density) and surfaced as descriptive hotspot context.
- Import
Info - An import declaration.
- Load
Return Key - A key returned from a SvelteKit route
load()function’s terminal return object literal. Harvested from+page.{ts,server.ts,js,server.js}files exporting aloadfunction. Consumed by theunused-load-data-keydetector, which flags a key read by no consumer. The span is stored as byte offsets (not anoxc_span::Span) so the type round-trips through the bitcode cache directly, mirroringDiKeySite::span_start/ComponentEmit::span_start. - Local
Type Declaration - A module-scope declaration that can be used as a TypeScript type.
- Member
Access - A static member access expression (e.g.,
Status.Active,MyClass.create()). - Member
Info - A member of an enum, class, or namespace.
- Misplaced
Directive Site - A
"use client"/"use server"directive string written as an expression statement inprogram.body(NOT the leading prologue), so the RSC bundler silently ignores it. One entry per offending occurrence. Consumed by themisplaced-directivedetector. - Module
Info - Extracted module information from a single file.
- Namespace
Object Alias - One alias entry tying an exported object’s dotted property path to a namespace import.
- Parse
Result - Result of parsing all files, including incremental cache statistics.
- Public
Signature Type Reference - A reference from an exported symbol’s public signature to a type name.
- ReExport
Info - A re-export declaration.
- Render
Edge - A render edge: one component rendering another (a capitalized or
member-expression JSX tag). Captured at extraction time with the child’s
written name; resolution of
child_component_nameto aFileId/export is deferred to graph build via the existing import map. - Require
Call Info - A
require()call. - Sanitized
Sink Arg - A captured sink argument that is itself a recognized sanitizer call.
- Security
Control Site - A known defensive control call site.
- Sink
Object Property - Static object-literal property metadata attached to a captured sink argument. Nested object paths are flattened with dot-separated keys.
- Sink
Site - A captured sink site. The visitor records every existing non-literal call / member-assign / member-call / tagged-template / jsx-attr sink site, and a small allowlist of literal-aware sites where the literal value is the signal. It knows nothing about CWE categories.
- Skipped
Security Callee Site - Span-only diagnostic for a skipped security callee inside one module.
- Tainted
Binding - A local binding tied to the flattened member-access path it was initialized
from. The analyze layer matches
source_pathagainst the data-driven source catalogue; when it matches,localis treated as carrying untrusted input.
Enums§
- Complexity
Contribution Kind - The syntactic construct that produced a single complexity increment.
- Complexity
Metric - Which complexity metric a
ComplexityContributionadds to. - Component
Function Kind - The syntactic shape of an identified React component definition. Drives the
abstain ladder later phases apply: a
forwardRef/memowrapper whose props come from an imported interface fallow cannot resolve must abstain (ADR-001), not guess. - DiFramework
- Which framework’s DI API a call site came from (drives the finding message).
- DiRole
- Which side of a dependency-injection link a call site represents.
- Export
Name - Export identifier.
- Flag
UseKind - The kind of feature flag pattern detected.
- Hook
UseKind - The kind of a React hook call.
Customcovers anyuse*-named call that is not one of the built-in hooks. - Imported
Name - How a symbol is imported.
- Member
Kind - The kind of member.
- Sanitizer
Scope - Sanitizer output domain. Kept intentionally narrow so a sanitizer for one domain cannot suppress a different sink family.
- Security
Control Kind - Defensive control family detected on a source to sink path.
- Security
UrlShape - Static URL construction shape captured for URL-shaped security sinks.
- Sink
ArgKind - The shape of the argument captured at a sink site. Category-blind like
SinkShape, but finer-grained: it lets the catalogue matcher require or exclude specific argument shapes. The discriminator is what distinguishes an unsafe SQL string concatenation or template-into-.execute()from a safely-parameterizedsql`${x}`tagged template, an object-literal.execute({ sql, args })argument, or a literal-aware sink argument. - Sink
Literal Value - Literal values attached to literal-aware security sink captures.
- Sink
Shape - The syntactic shape of a captured security sink site. Category-blind: the
extractor records the shape and the dotted/bare callee path; the analyze
layer matches it against the data-driven catalogue. See
crates/core/data/security_matchers.toml. - Skipped
Security Callee Expression Kind - Syntactic expression shape for a skipped security callee.
- Skipped
Security Callee Reason - Why a sink-shaped callee could not be flattened into a static catalogue path.
- Visibility
Tag - Visibility tag from JSDoc/TSDoc comments that suppresses unused-export detection.
Constants§
- PUBLIC_
ENV_ EXACT - Exact env var names that are public by convention (no prefix).
- PUBLIC_
ENV_ METADATA_ TOKENS - Env var-name tokens that usually describe public build or deployment metadata rather than secrets. Secret-shaped names win over these tokens.
- PUBLIC_
ENV_ PREFIXES - Env var-name prefixes that frameworks inline into the client bundle by
convention. A read of one of these is normal and safe, so it does NOT count
as a secret source (issue #890). Shared by the extract layer (so public env
vars never become source signals) and the bespoke
client-server-leakrule. - SECRET_
ENV_ TOKENS - Env var-name tokens that should keep a variable source-backed even when the
name also contains public metadata tokens such as
REForSHA.
Functions§
- byte_
offset_ to_ line_ col - Convert a byte offset to a 1-based line number and 0-based byte column.
- compute_
line_ offsets - Compute a table of line-start byte offsets from source text.
- is_
public_ env_ path - Whether a flattened member path is a PUBLIC env-secret read
(
process.env.NEXT_PUBLIC_X,import.meta.env.VITE_Y), which must not be recorded as a secret source. Non-env paths (req.query.id) are never public. - is_
public_ env_ var - Whether an env var name is public-by-convention (build-inlined into the client bundle), and therefore not a secret.