@zmdb/web 1.0.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +674 -0
- package/README.md +49 -0
- package/dist/app/bridge.d.ts +12 -0
- package/dist/app/bridge.d.ts.map +1 -0
- package/dist/app/bridge.js +16 -0
- package/dist/app/bridge.js.map +1 -0
- package/dist/app/index.d.ts +23 -0
- package/dist/app/index.d.ts.map +1 -0
- package/dist/app/index.js +47 -0
- package/dist/app/index.js.map +1 -0
- package/dist/bench/index.d.ts +68 -0
- package/dist/bench/index.d.ts.map +1 -0
- package/dist/bench/index.js +250 -0
- package/dist/bench/index.js.map +1 -0
- package/dist/compression/index.d.ts +13 -0
- package/dist/compression/index.d.ts.map +1 -0
- package/dist/compression/index.js +211 -0
- package/dist/compression/index.js.map +1 -0
- package/dist/context/index.d.ts +74 -0
- package/dist/context/index.d.ts.map +1 -0
- package/dist/context/index.js +118 -0
- package/dist/context/index.js.map +1 -0
- package/dist/contract/__fixtures__/http-client.generated.d.ts +70 -0
- package/dist/contract/__fixtures__/http-client.generated.d.ts.map +1 -0
- package/dist/contract/__fixtures__/http-client.generated.js +86 -0
- package/dist/contract/__fixtures__/http-client.generated.js.map +1 -0
- package/dist/contract/__fixtures__/http-convergence.d.ts +396 -0
- package/dist/contract/__fixtures__/http-convergence.d.ts.map +1 -0
- package/dist/contract/__fixtures__/http-convergence.js +425 -0
- package/dist/contract/__fixtures__/http-convergence.js.map +1 -0
- package/dist/contract/compiler/client.d.ts +12 -0
- package/dist/contract/compiler/client.d.ts.map +1 -0
- package/dist/contract/compiler/client.js +1293 -0
- package/dist/contract/compiler/client.js.map +1 -0
- package/dist/contract/compiler/index.d.ts +18 -0
- package/dist/contract/compiler/index.d.ts.map +1 -0
- package/dist/contract/compiler/index.js +1058 -0
- package/dist/contract/compiler/index.js.map +1 -0
- package/dist/contract/index.d.ts +237 -0
- package/dist/contract/index.d.ts.map +1 -0
- package/dist/contract/index.js +22 -0
- package/dist/contract/index.js.map +1 -0
- package/dist/csrf/index.d.ts +15 -0
- package/dist/csrf/index.d.ts.map +1 -0
- package/dist/csrf/index.js +218 -0
- package/dist/csrf/index.js.map +1 -0
- package/dist/data/index.d.ts +35 -0
- package/dist/data/index.d.ts.map +1 -0
- package/dist/data/index.js +58 -0
- package/dist/data/index.js.map +1 -0
- package/dist/devtools/index.d.ts +74 -0
- package/dist/devtools/index.d.ts.map +1 -0
- package/dist/devtools/index.js +552 -0
- package/dist/devtools/index.js.map +1 -0
- package/dist/dto-pipes/index.d.ts +45 -0
- package/dist/dto-pipes/index.d.ts.map +1 -0
- package/dist/dto-pipes/index.js +78 -0
- package/dist/dto-pipes/index.js.map +1 -0
- package/dist/gateways/index.d.ts +31 -0
- package/dist/gateways/index.d.ts.map +1 -0
- package/dist/gateways/index.js +138 -0
- package/dist/gateways/index.js.map +1 -0
- package/dist/health/index.d.ts +20 -0
- package/dist/health/index.d.ts.map +1 -0
- package/dist/health/index.js +148 -0
- package/dist/health/index.js.map +1 -0
- package/dist/http-token.d.ts +2 -0
- package/dist/http-token.d.ts.map +1 -0
- package/dist/http-token.js +21 -0
- package/dist/http-token.js.map +1 -0
- package/dist/index.d.ts +18 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +40 -0
- package/dist/index.js.map +1 -0
- package/dist/integrations/index.d.ts +11 -0
- package/dist/integrations/index.d.ts.map +1 -0
- package/dist/integrations/index.js +39 -0
- package/dist/integrations/index.js.map +1 -0
- package/dist/middleware/errors.d.ts +14 -0
- package/dist/middleware/errors.d.ts.map +1 -0
- package/dist/middleware/errors.js +18 -0
- package/dist/middleware/errors.js.map +1 -0
- package/dist/middleware/index.d.ts +46 -0
- package/dist/middleware/index.d.ts.map +1 -0
- package/dist/middleware/index.js +64 -0
- package/dist/middleware/index.js.map +1 -0
- package/dist/modules/__fixtures__/large-graph.d.ts +239 -0
- package/dist/modules/__fixtures__/large-graph.d.ts.map +1 -0
- package/dist/modules/__fixtures__/large-graph.js +483 -0
- package/dist/modules/__fixtures__/large-graph.js.map +1 -0
- package/dist/openapi/__fixtures__/entities.d.ts +8 -0
- package/dist/openapi/__fixtures__/entities.d.ts.map +1 -0
- package/dist/openapi/__fixtures__/entities.js +4 -0
- package/dist/openapi/__fixtures__/entities.js.map +1 -0
- package/dist/openapi/__fixtures__/openapi-tools.fixture.d.ts +38 -0
- package/dist/openapi/__fixtures__/openapi-tools.fixture.d.ts.map +1 -0
- package/dist/openapi/__fixtures__/openapi-tools.fixture.js +172 -0
- package/dist/openapi/__fixtures__/openapi-tools.fixture.js.map +1 -0
- package/dist/openapi/__fixtures__/route-schemas.d.ts +2 -0
- package/dist/openapi/__fixtures__/route-schemas.d.ts.map +1 -0
- package/dist/openapi/__fixtures__/route-schemas.js +17 -0
- package/dist/openapi/__fixtures__/route-schemas.js.map +1 -0
- package/dist/openapi/index.d.ts +61 -0
- package/dist/openapi/index.d.ts.map +1 -0
- package/dist/openapi/index.js +314 -0
- package/dist/openapi/index.js.map +1 -0
- package/dist/pipeline/guards.d.ts +9 -0
- package/dist/pipeline/guards.d.ts.map +1 -0
- package/dist/pipeline/guards.js +11 -0
- package/dist/pipeline/guards.js.map +1 -0
- package/dist/pipeline/index.d.ts +141 -0
- package/dist/pipeline/index.d.ts.map +1 -0
- package/dist/pipeline/index.js +1624 -0
- package/dist/pipeline/index.js.map +1 -0
- package/dist/routing/index.d.ts +40 -0
- package/dist/routing/index.d.ts.map +1 -0
- package/dist/routing/index.js +162 -0
- package/dist/routing/index.js.map +1 -0
- package/dist/static/index.d.ts +14 -0
- package/dist/static/index.d.ts.map +1 -0
- package/dist/static/index.js +348 -0
- package/dist/static/index.js.map +1 -0
- package/dist/testing/index.d.ts +20 -0
- package/dist/testing/index.d.ts.map +1 -0
- package/dist/testing/index.js +32 -0
- package/dist/testing/index.js.map +1 -0
- package/dist/traced-router.d.ts +5 -0
- package/dist/traced-router.d.ts.map +1 -0
- package/dist/traced-router.js +6 -0
- package/dist/traced-router.js.map +1 -0
- package/dist/upload/index.d.ts +28 -0
- package/dist/upload/index.d.ts.map +1 -0
- package/dist/upload/index.js +410 -0
- package/dist/upload/index.js.map +1 -0
- package/dist/versioning/index.d.ts +35 -0
- package/dist/versioning/index.d.ts.map +1 -0
- package/dist/versioning/index.js +66 -0
- package/dist/versioning/index.js.map +1 -0
- package/dist/versioning/runtime.d.ts +5 -0
- package/dist/versioning/runtime.d.ts.map +1 -0
- package/dist/versioning/runtime.js +34 -0
- package/dist/versioning/runtime.js.map +1 -0
- package/package.json +143 -0
- package/src/app/bridge.ts +39 -0
- package/src/app/index.ts +76 -0
- package/src/bench/index.ts +329 -0
- package/src/compression/index.ts +255 -0
- package/src/context/index.ts +181 -0
- package/src/contract/__fixtures__/http-client.generated.ts +73 -0
- package/src/contract/__fixtures__/http-client.generated.ts.map +1 -0
- package/src/contract/__fixtures__/http-convergence.ts +564 -0
- package/src/contract/compiler/client.ts +1518 -0
- package/src/contract/compiler/index.ts +1457 -0
- package/src/contract/index.ts +266 -0
- package/src/csrf/index.ts +264 -0
- package/src/data/index.ts +65 -0
- package/src/devtools/index.ts +727 -0
- package/src/dto-pipes/index.ts +93 -0
- package/src/gateways/index.ts +180 -0
- package/src/health/index.ts +198 -0
- package/src/http-token.ts +22 -0
- package/src/index.ts +167 -0
- package/src/integrations/index.ts +50 -0
- package/src/middleware/errors.ts +17 -0
- package/src/middleware/index.ts +108 -0
- package/src/modules/__fixtures__/large-graph.ts +540 -0
- package/src/openapi/__fixtures__/entities.ts +19 -0
- package/src/openapi/__fixtures__/openapi-tools.fixture.ts +212 -0
- package/src/openapi/__fixtures__/route-schemas.ts +27 -0
- package/src/openapi/index.ts +483 -0
- package/src/pipeline/guards.ts +23 -0
- package/src/pipeline/index.ts +2041 -0
- package/src/routing/index.ts +201 -0
- package/src/static/index.ts +443 -0
- package/src/testing/index.ts +58 -0
- package/src/traced-router.ts +8 -0
- package/src/upload/index.ts +489 -0
- package/src/versioning/index.ts +106 -0
- package/src/versioning/runtime.ts +38 -0
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { type CoreSchema } from '@zmdb/schema';
|
|
2
|
+
import { type CodecRegistry, type Variant } from '@zmdb/schema/ir';
|
|
3
|
+
/**
|
|
4
|
+
* Adapt a validator into a pipeline `validateBody` hook. Pass any function that
|
|
5
|
+
* returns the validated value or throws — e.g. `@zmdb/validator`'s
|
|
6
|
+
* `assert<CreateDTO<T>>`. The framework embeds no parser of its own.
|
|
7
|
+
*/
|
|
8
|
+
export declare function validateWith<T>(validator: (raw: unknown) => T): (raw: unknown) => T;
|
|
9
|
+
/**
|
|
10
|
+
* The wire→app decode, at the boundary and nowhere else (plan D3).
|
|
11
|
+
*
|
|
12
|
+
* A column has three types, and two of them meet here: JSON carries a `timestamp` as an
|
|
13
|
+
* ISO-8601 string and a `bigint` as a decimal one, while a handler, a `CreateDTO<T>` and
|
|
14
|
+
* the repository all hold a `Date` and a `bigint`. Something has to convert, and if it is
|
|
15
|
+
* not one function at the edge then it is every handler, differently — which is the state
|
|
16
|
+
* in which nobody noticed that the repository accepted both and the DDL was wrong.
|
|
17
|
+
*
|
|
18
|
+
* Put it *before* validation in the chain: it decodes, the validator then checks the app
|
|
19
|
+
* type. It converts and never rejects — a string that is not a date survives as a string,
|
|
20
|
+
* so the validator reports it rather than the handler receiving `Invalid Date`.
|
|
21
|
+
*
|
|
22
|
+
* ```ts
|
|
23
|
+
* dtoChain({ decode: wireDecoder(OrderSchema, 'create'), validate: assert<CreateDTO<Order>> })
|
|
24
|
+
* ```
|
|
25
|
+
*/
|
|
26
|
+
export declare function wireDecoder(schema: CoreSchema<string>, variant?: Variant, codecs?: CodecRegistry): (raw: unknown) => unknown;
|
|
27
|
+
/**
|
|
28
|
+
* The app→wire encode, for a response: the same crossing in the other direction.
|
|
29
|
+
*
|
|
30
|
+
* A `Date` does not survive `JSON.stringify` as anything the published document describes
|
|
31
|
+
* — it becomes an ISO string, which happens to be right — and a `bigint` does not survive
|
|
32
|
+
* it at all (`TypeError`). Both are the wire type of a column, so both come from here.
|
|
33
|
+
*/
|
|
34
|
+
export declare function wireEncoder(schema: CoreSchema<string>, codecs?: CodecRegistry): (result: unknown) => unknown;
|
|
35
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/data/index.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,EAA0B,KAAK,aAAa,EAAE,KAAK,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAE3F;;;;GAIG;AACH,wBAAgB,YAAY,CAAC,CAAC,EAAE,SAAS,EAAE,CAAC,GAAG,EAAE,OAAO,KAAK,CAAC,GAAG,CAAC,GAAG,EAAE,OAAO,KAAK,CAAC,CAEnF;AAOD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,WAAW,CACzB,MAAM,EAAE,UAAU,CAAC,MAAM,CAAC,EAC1B,OAAO,GAAE,OAAkB,EAC3B,MAAM,GAAE,aAAkB,GACzB,CAAC,GAAG,EAAE,OAAO,KAAK,OAAO,CAG3B;AAED;;;;;;GAMG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,UAAU,CAAC,MAAM,CAAC,EAAE,MAAM,GAAE,aAAkB,GAAG,CAAC,MAAM,EAAE,OAAO,KAAK,OAAO,CAMhH"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
// @zmdb/web — HTTP data-boundary adapters (epic #277, spec ./SPEC.md).
|
|
2
|
+
// Repository injection is app-owned; this module converts wire values and
|
|
3
|
+
// adapts validators for the request pipeline.
|
|
4
|
+
//
|
|
5
|
+
// "No runtime parser" still holds with `wireDecoder` here: it converts the two column
|
|
6
|
+
// types JSON cannot carry (a `timestamp`, a `bigint`) into the values the app layer holds,
|
|
7
|
+
// and it accepts and rejects nothing. Validation remains the consumer's AOT `assert`.
|
|
8
|
+
import {} from '@zmdb/schema';
|
|
9
|
+
import { decodeWire, encodeWire } from '@zmdb/schema/ir';
|
|
10
|
+
/**
|
|
11
|
+
* Adapt a validator into a pipeline `validateBody` hook. Pass any function that
|
|
12
|
+
* returns the validated value or throws — e.g. `@zmdb/validator`'s
|
|
13
|
+
* `assert<CreateDTO<T>>`. The framework embeds no parser of its own.
|
|
14
|
+
*/
|
|
15
|
+
export function validateWith(validator) {
|
|
16
|
+
return validator;
|
|
17
|
+
}
|
|
18
|
+
/** A JSON object body — not an array, which is a valid JSON document and not a payload. */
|
|
19
|
+
function isBody(value) {
|
|
20
|
+
return typeof value === 'object' && value !== null && !Array.isArray(value);
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* The wire→app decode, at the boundary and nowhere else (plan D3).
|
|
24
|
+
*
|
|
25
|
+
* A column has three types, and two of them meet here: JSON carries a `timestamp` as an
|
|
26
|
+
* ISO-8601 string and a `bigint` as a decimal one, while a handler, a `CreateDTO<T>` and
|
|
27
|
+
* the repository all hold a `Date` and a `bigint`. Something has to convert, and if it is
|
|
28
|
+
* not one function at the edge then it is every handler, differently — which is the state
|
|
29
|
+
* in which nobody noticed that the repository accepted both and the DDL was wrong.
|
|
30
|
+
*
|
|
31
|
+
* Put it *before* validation in the chain: it decodes, the validator then checks the app
|
|
32
|
+
* type. It converts and never rejects — a string that is not a date survives as a string,
|
|
33
|
+
* so the validator reports it rather than the handler receiving `Invalid Date`.
|
|
34
|
+
*
|
|
35
|
+
* ```ts
|
|
36
|
+
* dtoChain({ decode: wireDecoder(OrderSchema, 'create'), validate: assert<CreateDTO<Order>> })
|
|
37
|
+
* ```
|
|
38
|
+
*/
|
|
39
|
+
export function wireDecoder(schema, variant = 'create', codecs = {}) {
|
|
40
|
+
const ir = schema.ir;
|
|
41
|
+
return (raw) => (isBody(raw) ? decodeWire(ir, variant, raw, codecs) : raw);
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* The app→wire encode, for a response: the same crossing in the other direction.
|
|
45
|
+
*
|
|
46
|
+
* A `Date` does not survive `JSON.stringify` as anything the published document describes
|
|
47
|
+
* — it becomes an ISO string, which happens to be right — and a `bigint` does not survive
|
|
48
|
+
* it at all (`TypeError`). Both are the wire type of a column, so both come from here.
|
|
49
|
+
*/
|
|
50
|
+
export function wireEncoder(schema, codecs = {}) {
|
|
51
|
+
const ir = schema.ir;
|
|
52
|
+
return (result) => {
|
|
53
|
+
if (Array.isArray(result))
|
|
54
|
+
return result.map(row => (isBody(row) ? encodeWire(ir, row, codecs) : row));
|
|
55
|
+
return isBody(result) ? encodeWire(ir, result, codecs) : result;
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/data/index.ts"],"names":[],"mappings":"AAAA,uEAAuE;AACvE,0EAA0E;AAC1E,8CAA8C;AAC9C,EAAE;AACF,sFAAsF;AACtF,2FAA2F;AAC3F,sFAAsF;AAEtF,OAAO,EAAmB,MAAM,cAAc,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,UAAU,EAAoC,MAAM,iBAAiB,CAAC;AAE3F;;;;GAIG;AACH,MAAM,UAAU,YAAY,CAAI,SAA8B;IAC5D,OAAO,SAAS,CAAC;AACnB,CAAC;AAED,2FAA2F;AAC3F,SAAS,MAAM,CAAC,KAAc;IAC5B,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;AAC9E,CAAC;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,UAAU,WAAW,CACzB,MAA0B,EAC1B,OAAO,GAAY,QAAQ,EAC3B,MAAM,GAAkB,EAAE;IAE1B,MAAM,EAAE,GAAG,MAAM,CAAC,EAAE,CAAC;IACrB,OAAO,CAAC,GAAY,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,EAAE,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;AACtF,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,WAAW,CAAC,MAA0B,EAAE,MAAM,GAAkB,EAAE;IAChF,MAAM,EAAE,GAAG,MAAM,CAAC,EAAE,CAAC;IACrB,OAAO,CAAC,MAAe,EAAE,EAAE;QACzB,IAAI,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC;YAAE,OAAO,MAAM,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,EAAE,EAAE,GAAG,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;QACvG,OAAO,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,EAAE,EAAE,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC;IAClE,CAAC,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import type { Scope } from '@zmdb/app/di';
|
|
2
|
+
import { type ModuleClass } from '@zmdb/app/modules';
|
|
3
|
+
import { type HttpMethod } from '../routing/index.js';
|
|
4
|
+
export interface ModuleNode {
|
|
5
|
+
readonly id: string;
|
|
6
|
+
readonly name: string;
|
|
7
|
+
readonly lazy: boolean;
|
|
8
|
+
readonly imports: readonly string[];
|
|
9
|
+
}
|
|
10
|
+
export type ProviderNode = {
|
|
11
|
+
readonly kind: 'value';
|
|
12
|
+
readonly id: string;
|
|
13
|
+
readonly token: string;
|
|
14
|
+
readonly module: string;
|
|
15
|
+
} | {
|
|
16
|
+
readonly kind: 'factory';
|
|
17
|
+
readonly id: string;
|
|
18
|
+
readonly token: string;
|
|
19
|
+
readonly module: string;
|
|
20
|
+
readonly scope: Scope;
|
|
21
|
+
/** Factory bodies are opaque, so their dependency edges are unknowable. */
|
|
22
|
+
readonly dependencies: readonly string[] | null;
|
|
23
|
+
};
|
|
24
|
+
export interface RouteNode {
|
|
25
|
+
readonly method: HttpMethod;
|
|
26
|
+
readonly path: string;
|
|
27
|
+
readonly handler: string;
|
|
28
|
+
}
|
|
29
|
+
export interface ClassNode {
|
|
30
|
+
readonly id: string;
|
|
31
|
+
readonly name: string;
|
|
32
|
+
readonly module: string;
|
|
33
|
+
readonly routes: readonly RouteNode[];
|
|
34
|
+
readonly dependencies: readonly string[];
|
|
35
|
+
}
|
|
36
|
+
export type FindingKind = 'cycle' | 'unresolved-token' | 'eager-depends-on-lazy' | 'duplicate-provider' | 'shadowed-route' | 'duplicate-token-description' | 'anonymous-class';
|
|
37
|
+
export interface Finding {
|
|
38
|
+
readonly kind: FindingKind;
|
|
39
|
+
readonly severity: 'error' | 'warning';
|
|
40
|
+
readonly message: string;
|
|
41
|
+
readonly subject: string;
|
|
42
|
+
readonly path?: readonly string[];
|
|
43
|
+
}
|
|
44
|
+
export interface GraphDescription {
|
|
45
|
+
readonly modules: readonly ModuleNode[];
|
|
46
|
+
readonly providers: readonly ProviderNode[];
|
|
47
|
+
readonly controllers: readonly ClassNode[];
|
|
48
|
+
readonly findings: readonly Finding[];
|
|
49
|
+
}
|
|
50
|
+
export interface GraphFilter {
|
|
51
|
+
readonly module?: string;
|
|
52
|
+
readonly token?: string;
|
|
53
|
+
readonly depth?: number;
|
|
54
|
+
readonly providers?: boolean;
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Reconstruct the declared graph without constructing a provider or controller.
|
|
58
|
+
*
|
|
59
|
+
* A cycle is returned as a finding instead of thrown, so this remains useful for
|
|
60
|
+
* the graphs that `compileModule` correctly refuses to boot.
|
|
61
|
+
*/
|
|
62
|
+
export declare function describeGraph(rootModule: ModuleClass): GraphDescription;
|
|
63
|
+
/**
|
|
64
|
+
* Return known direct reverse edges.
|
|
65
|
+
*
|
|
66
|
+
* Factory provider bodies are opaque. For a provider query, the sentinel keeps
|
|
67
|
+
* that incompleteness visible instead of returning an unsafe "nothing else".
|
|
68
|
+
*/
|
|
69
|
+
export declare function dependentsOf(graph: GraphDescription, id: string): readonly string[];
|
|
70
|
+
/** Render a deterministic, readable module tree. */
|
|
71
|
+
export declare function renderTree(graph: GraphDescription, filter?: GraphFilter): string;
|
|
72
|
+
/** Render Graphviz DOT with every id and label quoted. */
|
|
73
|
+
export declare function renderDot(graph: GraphDescription, filter?: GraphFilter): string;
|
|
74
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/devtools/index.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,KAAK,EAAS,MAAM,cAAc,CAAC;AAEjD,OAAO,EAAe,KAAK,WAAW,EAAoC,MAAM,mBAAmB,CAAC;AAEpG,OAAO,EAAa,KAAK,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEjE,MAAM,WAAW,UAAU;IACzB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;IACvB,QAAQ,CAAC,OAAO,EAAE,SAAS,MAAM,EAAE,CAAC;CACrC;AAED,MAAM,MAAM,YAAY,GACpB;IACE,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;IACvB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CACzB,GACD;IACE,QAAQ,CAAC,IAAI,EAAE,SAAS,CAAC;IACzB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;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