Logo Xantham

Grouping Module

Functions and values

Function or value Description

classify packageDir symbol

Full Usage: classify packageDir symbol

Parameters:
Returns: PackageId

Classifies a symbol's origin group (O7) from its first declaration's file path: under the package directory and outside any `node_modules` below it is the entry package; the compiler's default libs are the compiler-lib group; under a `node_modules` entry is that dependency, at whatever depth npm installed it; anything else - including anonymous shapes with no declaration - is unclassified, which dispositions as the entry group. The default libs are recognised three ways because the compiler serves them three ways: from the platform package (`node_modules/@typescript/typescript-/lib/lib.*.d.ts` - what the live wire reports), from `typescript/lib`, or as `bundled:` pseudo-paths for the embedded copies. A non-entry `lib.*.d.ts` anywhere else still classifies as compiler lib rather than unclassified: unclassified means Ship, and full derivation of a mistaken standard-lib file is the expensive failure, while a mis-grouped oddball is a visible finding.

packageDir : string
symbol : SymbolResponse voption
Returns: PackageId

declOrder declarations

Full Usage: declOrder declarations

Parameters:
    declarations : string[] voption

Returns: DeclOrder option

Parses the ordering key out of a symbol's first declaration handle. A handle is `index.kind.path` where only the path may contain further dots.

declarations : string[] voption
Returns: DeclOrder option

Type something to start searching.