@glion/annotate-profile-datatypes 0.14.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 +21 -0
- package/dist/index.d.ts +61 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +72 -0
- package/dist/index.js.map +1 -0
- package/package.json +65 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2023 Rethink Health
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import type { Root } from "@glion/ast";
|
|
2
|
+
import type { Plugin } from "unified";
|
|
3
|
+
declare module "@glion/ast" {
|
|
4
|
+
interface FieldRepetitionData {
|
|
5
|
+
/** Datatype ID for this field (e.g., "ST", "CWE", "MSG"). */
|
|
6
|
+
datatypeId?: string | undefined;
|
|
7
|
+
/** Datatype kind: "primitive" or "composite". */
|
|
8
|
+
kind?: string | undefined;
|
|
9
|
+
/** Datatype title (e.g., "String Data", "Coded with Exceptions"). */
|
|
10
|
+
title?: string | undefined;
|
|
11
|
+
}
|
|
12
|
+
interface ComponentData {
|
|
13
|
+
/** Component identifier (e.g., "CWE.1", "XPN.2"). */
|
|
14
|
+
id?: string | undefined;
|
|
15
|
+
/** Component name from the parent datatype definition. */
|
|
16
|
+
name?: string | undefined;
|
|
17
|
+
/** Whether this component is required in the parent datatype. */
|
|
18
|
+
required?: boolean | undefined;
|
|
19
|
+
/** Datatype ID for this component (e.g., "ST", "ID"). */
|
|
20
|
+
datatypeId?: string | undefined;
|
|
21
|
+
/** Maximum allowed length for this component. */
|
|
22
|
+
maxLength?: number | undefined;
|
|
23
|
+
/** Datatype kind: "primitive" or "composite". */
|
|
24
|
+
kind?: string | undefined;
|
|
25
|
+
/** Datatype title (e.g., "String Data"). */
|
|
26
|
+
title?: string | undefined;
|
|
27
|
+
}
|
|
28
|
+
interface SubcomponentData {
|
|
29
|
+
/** Subcomponent identifier (e.g., "FN.1", "HD.2"). */
|
|
30
|
+
id?: string | undefined;
|
|
31
|
+
/** Subcomponent name from the parent component's datatype definition. */
|
|
32
|
+
name?: string | undefined;
|
|
33
|
+
/** Whether this subcomponent is required. */
|
|
34
|
+
required?: boolean | undefined;
|
|
35
|
+
/** Datatype ID for this subcomponent. */
|
|
36
|
+
datatypeId?: string | undefined;
|
|
37
|
+
/** Datatype kind: "primitive" or "composite". */
|
|
38
|
+
kind?: string | undefined;
|
|
39
|
+
/** Datatype title. */
|
|
40
|
+
title?: string | undefined;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Unified plugin that annotates FieldRepetition, Component, and Subcomponent
|
|
45
|
+
* nodes with datatype profile metadata using a stop-at-primitive cascade.
|
|
46
|
+
*
|
|
47
|
+
* Annotation flows down the AST and stops at the node where the primitive
|
|
48
|
+
* value lives:
|
|
49
|
+
* - Primitive field → stops at FieldRepetition
|
|
50
|
+
* - Composite field with primitive components → stops at Component
|
|
51
|
+
* - Composite field with composite components → stops at Subcomponent
|
|
52
|
+
*
|
|
53
|
+
* `kind: "primitive"` = the value is here.
|
|
54
|
+
* `kind: "composite"` = look at children.
|
|
55
|
+
* No annotation = the value lives on an ancestor.
|
|
56
|
+
*
|
|
57
|
+
* Requires the fields annotator to run first (preset guarantees ordering).
|
|
58
|
+
*/
|
|
59
|
+
export declare const hl7v2AnnotateProfileDatatypes: Plugin<[], Root, Root>;
|
|
60
|
+
export default hl7v2AnnotateProfileDatatypes;
|
|
61
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAqC,IAAI,EAAE,MAAM,YAAY,CAAC;AAE1E,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAGtC,OAAO,QAAQ,YAAY,CAAC;IAC1B,UAAU,mBAAmB;QAC3B,6DAA6D;QAC7D,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAChC,iDAAiD;QACjD,IAAI,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAC1B,qEAAqE;QACrE,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;KAC5B;IACD,UAAU,aAAa;QACrB,qDAAqD;QACrD,EAAE,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QACxB,0DAA0D;QAC1D,IAAI,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAC1B,iEAAiE;QACjE,QAAQ,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;QAC/B,yDAAyD;QACzD,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAChC,iDAAiD;QACjD,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAC/B,iDAAiD;QACjD,IAAI,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAC1B,4CAA4C;QAC5C,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;KAC5B;IACD,UAAU,gBAAgB;QACxB,sDAAsD;QACtD,EAAE,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QACxB,yEAAyE;QACzE,IAAI,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAC1B,6CAA6C;QAC7C,QAAQ,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;QAC/B,yCAAyC;QACzC,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAChC,iDAAiD;QACjD,IAAI,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QAC1B,sBAAsB;QACtB,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;KAC5B;CACF;AAED;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,6BAA6B,EAAE,MAAM,CAAC,EAAE,EAAE,IAAI,EAAE,IAAI,CAkG9D,CAAC;AAEJ,eAAe,6BAA6B,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { SKIP, visit } from "@glion/util-visit";
|
|
2
|
+
//#region src/index.ts
|
|
3
|
+
/**
|
|
4
|
+
* Unified plugin that annotates FieldRepetition, Component, and Subcomponent
|
|
5
|
+
* nodes with datatype profile metadata using a stop-at-primitive cascade.
|
|
6
|
+
*
|
|
7
|
+
* Annotation flows down the AST and stops at the node where the primitive
|
|
8
|
+
* value lives:
|
|
9
|
+
* - Primitive field → stops at FieldRepetition
|
|
10
|
+
* - Composite field with primitive components → stops at Component
|
|
11
|
+
* - Composite field with composite components → stops at Subcomponent
|
|
12
|
+
*
|
|
13
|
+
* `kind: "primitive"` = the value is here.
|
|
14
|
+
* `kind: "composite"` = look at children.
|
|
15
|
+
* No annotation = the value lives on an ancestor.
|
|
16
|
+
*
|
|
17
|
+
* Requires the fields annotator to run first (preset guarantees ordering).
|
|
18
|
+
*/
|
|
19
|
+
const hl7v2AnnotateProfileDatatypes = () => (tree, file) => {
|
|
20
|
+
const ctx = file.data.profile;
|
|
21
|
+
if (!ctx) return tree;
|
|
22
|
+
visit(tree, "field-repetition", (rep, ancestors) => {
|
|
23
|
+
const datatypeId = (ancestors.at(-1)?.data)?.datatype;
|
|
24
|
+
const dtDef = datatypeId ? ctx.datatypes.get(datatypeId) : void 0;
|
|
25
|
+
if (!dtDef) return;
|
|
26
|
+
if (!rep.data) rep.data = {};
|
|
27
|
+
rep.data.datatypeId = dtDef.id;
|
|
28
|
+
rep.data.kind = dtDef.kind;
|
|
29
|
+
if (dtDef.title !== void 0) rep.data.title = dtDef.title;
|
|
30
|
+
});
|
|
31
|
+
visit(tree, "component", (component, ancestors, info) => {
|
|
32
|
+
const rep = ancestors.at(-1);
|
|
33
|
+
if (rep?.data?.kind !== "composite" || !rep.data.datatypeId) return SKIP;
|
|
34
|
+
const dtDef = ctx.datatypes.get(rep.data.datatypeId);
|
|
35
|
+
if (!dtDef) return SKIP;
|
|
36
|
+
const compProfile = dtDef.componentsBySequence.get(info.sequence);
|
|
37
|
+
if (!compProfile) return SKIP;
|
|
38
|
+
if (!component.data) component.data = {};
|
|
39
|
+
component.data.id = `${dtDef.id}.${info.sequence}`;
|
|
40
|
+
component.data.name = compProfile.name;
|
|
41
|
+
component.data.required = compProfile.required;
|
|
42
|
+
component.data.datatypeId = compProfile.datatypeId;
|
|
43
|
+
if (compProfile.maxLength !== void 0) component.data.maxLength = compProfile.maxLength;
|
|
44
|
+
const compDtDef = ctx.datatypes.get(compProfile.datatypeId);
|
|
45
|
+
if (compDtDef) {
|
|
46
|
+
component.data.kind = compDtDef.kind;
|
|
47
|
+
if (compDtDef.title !== void 0) component.data.title = compDtDef.title;
|
|
48
|
+
}
|
|
49
|
+
return SKIP;
|
|
50
|
+
});
|
|
51
|
+
visit(tree, "subcomponent", (subcomponent, ancestors, info) => {
|
|
52
|
+
const component = ancestors.at(-1);
|
|
53
|
+
if (component?.data?.kind !== "composite" || !component.data.datatypeId) return;
|
|
54
|
+
const subProfile = ctx.datatypes.get(component.data.datatypeId)?.componentsBySequence.get(info.sequence);
|
|
55
|
+
if (!subProfile) return;
|
|
56
|
+
if (!subcomponent.data) subcomponent.data = {};
|
|
57
|
+
subcomponent.data.id = `${component.data.datatypeId}.${info.sequence}`;
|
|
58
|
+
subcomponent.data.name = subProfile.name;
|
|
59
|
+
subcomponent.data.required = subProfile.required;
|
|
60
|
+
subcomponent.data.datatypeId = subProfile.datatypeId;
|
|
61
|
+
const subDtDef = ctx.datatypes.get(subProfile.datatypeId);
|
|
62
|
+
if (subDtDef) {
|
|
63
|
+
subcomponent.data.kind = subDtDef.kind;
|
|
64
|
+
if (subDtDef.title !== void 0) subcomponent.data.title = subDtDef.title;
|
|
65
|
+
}
|
|
66
|
+
});
|
|
67
|
+
return tree;
|
|
68
|
+
};
|
|
69
|
+
//#endregion
|
|
70
|
+
export { hl7v2AnnotateProfileDatatypes as default, hl7v2AnnotateProfileDatatypes };
|
|
71
|
+
|
|
72
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["// oxlint-disable-next-line no-unused-vars -- triggers VFile DataMap augmentation\nimport type { ProfileContext } from \"@glion/annotate-profile-context\";\nimport type { Component, Field, FieldRepetition, Root } from \"@glion/ast\";\nimport { SKIP, visit } from \"@glion/util-visit\";\nimport type { Plugin } from \"unified\";\nimport type { VFile } from \"vfile\";\n\ndeclare module \"@glion/ast\" {\n interface FieldRepetitionData {\n /** Datatype ID for this field (e.g., \"ST\", \"CWE\", \"MSG\"). */\n datatypeId?: string | undefined;\n /** Datatype kind: \"primitive\" or \"composite\". */\n kind?: string | undefined;\n /** Datatype title (e.g., \"String Data\", \"Coded with Exceptions\"). */\n title?: string | undefined;\n }\n interface ComponentData {\n /** Component identifier (e.g., \"CWE.1\", \"XPN.2\"). */\n id?: string | undefined;\n /** Component name from the parent datatype definition. */\n name?: string | undefined;\n /** Whether this component is required in the parent datatype. */\n required?: boolean | undefined;\n /** Datatype ID for this component (e.g., \"ST\", \"ID\"). */\n datatypeId?: string | undefined;\n /** Maximum allowed length for this component. */\n maxLength?: number | undefined;\n /** Datatype kind: \"primitive\" or \"composite\". */\n kind?: string | undefined;\n /** Datatype title (e.g., \"String Data\"). */\n title?: string | undefined;\n }\n interface SubcomponentData {\n /** Subcomponent identifier (e.g., \"FN.1\", \"HD.2\"). */\n id?: string | undefined;\n /** Subcomponent name from the parent component's datatype definition. */\n name?: string | undefined;\n /** Whether this subcomponent is required. */\n required?: boolean | undefined;\n /** Datatype ID for this subcomponent. */\n datatypeId?: string | undefined;\n /** Datatype kind: \"primitive\" or \"composite\". */\n kind?: string | undefined;\n /** Datatype title. */\n title?: string | undefined;\n }\n}\n\n/**\n * Unified plugin that annotates FieldRepetition, Component, and Subcomponent\n * nodes with datatype profile metadata using a stop-at-primitive cascade.\n *\n * Annotation flows down the AST and stops at the node where the primitive\n * value lives:\n * - Primitive field → stops at FieldRepetition\n * - Composite field with primitive components → stops at Component\n * - Composite field with composite components → stops at Subcomponent\n *\n * `kind: \"primitive\"` = the value is here.\n * `kind: \"composite\"` = look at children.\n * No annotation = the value lives on an ancestor.\n *\n * Requires the fields annotator to run first (preset guarantees ordering).\n */\nexport const hl7v2AnnotateProfileDatatypes: Plugin<[], Root, Root> =\n () => (tree: Root, file: VFile) => {\n const ctx = file.data.profile;\n if (!ctx) {\n return tree;\n }\n\n // Pass 1: field-repetitions — entry point for the cascade\n visit(tree, \"field-repetition\", (rep, ancestors) => {\n const field = ancestors.at(-1) as Field | undefined;\n const datatypeId = (field?.data as Record<string, unknown> | undefined)\n ?.datatype as string | undefined;\n\n const dtDef = datatypeId ? ctx.datatypes.get(datatypeId) : undefined;\n if (!dtDef) {\n return;\n }\n\n if (!rep.data) {\n rep.data = {};\n }\n rep.data.datatypeId = dtDef.id;\n rep.data.kind = dtDef.kind;\n if (dtDef.title !== undefined) {\n rep.data.title = dtDef.title;\n }\n });\n\n // Pass 2: components — only when parent repetition is composite\n visit(tree, \"component\", (component, ancestors, info) => {\n const rep = ancestors.at(-1) as FieldRepetition | undefined;\n if (rep?.data?.kind !== \"composite\" || !rep.data.datatypeId) {\n return SKIP;\n }\n\n const dtDef = ctx.datatypes.get(rep.data.datatypeId);\n if (!dtDef) {\n return SKIP;\n }\n\n const compProfile = dtDef.componentsBySequence.get(info.sequence);\n if (!compProfile) {\n return SKIP;\n }\n\n if (!component.data) {\n component.data = {};\n }\n component.data.id = `${dtDef.id}.${info.sequence}`;\n component.data.name = compProfile.name;\n component.data.required = compProfile.required;\n component.data.datatypeId = compProfile.datatypeId;\n if (compProfile.maxLength !== undefined) {\n component.data.maxLength = compProfile.maxLength;\n }\n\n const compDtDef = ctx.datatypes.get(compProfile.datatypeId);\n if (compDtDef) {\n component.data.kind = compDtDef.kind;\n if (compDtDef.title !== undefined) {\n component.data.title = compDtDef.title;\n }\n }\n\n return SKIP;\n });\n\n // Pass 3: subcomponents — only when parent component is composite\n visit(tree, \"subcomponent\", (subcomponent, ancestors, info) => {\n const component = ancestors.at(-1) as Component | undefined;\n if (component?.data?.kind !== \"composite\" || !component.data.datatypeId) {\n return;\n }\n\n const compDtDef = ctx.datatypes.get(component.data.datatypeId);\n const subProfile = compDtDef?.componentsBySequence.get(info.sequence);\n if (!subProfile) {\n return;\n }\n\n if (!subcomponent.data) {\n subcomponent.data = {};\n }\n subcomponent.data.id = `${component.data.datatypeId}.${info.sequence}`;\n subcomponent.data.name = subProfile.name;\n subcomponent.data.required = subProfile.required;\n subcomponent.data.datatypeId = subProfile.datatypeId;\n\n const subDtDef = ctx.datatypes.get(subProfile.datatypeId);\n if (subDtDef) {\n subcomponent.data.kind = subDtDef.kind;\n if (subDtDef.title !== undefined) {\n subcomponent.data.title = subDtDef.title;\n }\n }\n });\n\n return tree;\n };\n\nexport default hl7v2AnnotateProfileDatatypes;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAgEA,MAAa,uCACJ,MAAY,SAAgB;CACjC,MAAM,MAAM,KAAK,KAAK;AACtB,KAAI,CAAC,IACH,QAAO;AAIT,OAAM,MAAM,qBAAqB,KAAK,cAAc;EAElD,MAAM,cADQ,UAAU,GAAG,GAAG,EACH,OACvB;EAEJ,MAAM,QAAQ,aAAa,IAAI,UAAU,IAAI,WAAW,GAAG,KAAA;AAC3D,MAAI,CAAC,MACH;AAGF,MAAI,CAAC,IAAI,KACP,KAAI,OAAO,EAAE;AAEf,MAAI,KAAK,aAAa,MAAM;AAC5B,MAAI,KAAK,OAAO,MAAM;AACtB,MAAI,MAAM,UAAU,KAAA,EAClB,KAAI,KAAK,QAAQ,MAAM;GAEzB;AAGF,OAAM,MAAM,cAAc,WAAW,WAAW,SAAS;EACvD,MAAM,MAAM,UAAU,GAAG,GAAG;AAC5B,MAAI,KAAK,MAAM,SAAS,eAAe,CAAC,IAAI,KAAK,WAC/C,QAAO;EAGT,MAAM,QAAQ,IAAI,UAAU,IAAI,IAAI,KAAK,WAAW;AACpD,MAAI,CAAC,MACH,QAAO;EAGT,MAAM,cAAc,MAAM,qBAAqB,IAAI,KAAK,SAAS;AACjE,MAAI,CAAC,YACH,QAAO;AAGT,MAAI,CAAC,UAAU,KACb,WAAU,OAAO,EAAE;AAErB,YAAU,KAAK,KAAK,GAAG,MAAM,GAAG,GAAG,KAAK;AACxC,YAAU,KAAK,OAAO,YAAY;AAClC,YAAU,KAAK,WAAW,YAAY;AACtC,YAAU,KAAK,aAAa,YAAY;AACxC,MAAI,YAAY,cAAc,KAAA,EAC5B,WAAU,KAAK,YAAY,YAAY;EAGzC,MAAM,YAAY,IAAI,UAAU,IAAI,YAAY,WAAW;AAC3D,MAAI,WAAW;AACb,aAAU,KAAK,OAAO,UAAU;AAChC,OAAI,UAAU,UAAU,KAAA,EACtB,WAAU,KAAK,QAAQ,UAAU;;AAIrC,SAAO;GACP;AAGF,OAAM,MAAM,iBAAiB,cAAc,WAAW,SAAS;EAC7D,MAAM,YAAY,UAAU,GAAG,GAAG;AAClC,MAAI,WAAW,MAAM,SAAS,eAAe,CAAC,UAAU,KAAK,WAC3D;EAIF,MAAM,aADY,IAAI,UAAU,IAAI,UAAU,KAAK,WAAW,EAChC,qBAAqB,IAAI,KAAK,SAAS;AACrE,MAAI,CAAC,WACH;AAGF,MAAI,CAAC,aAAa,KAChB,cAAa,OAAO,EAAE;AAExB,eAAa,KAAK,KAAK,GAAG,UAAU,KAAK,WAAW,GAAG,KAAK;AAC5D,eAAa,KAAK,OAAO,WAAW;AACpC,eAAa,KAAK,WAAW,WAAW;AACxC,eAAa,KAAK,aAAa,WAAW;EAE1C,MAAM,WAAW,IAAI,UAAU,IAAI,WAAW,WAAW;AACzD,MAAI,UAAU;AACZ,gBAAa,KAAK,OAAO,SAAS;AAClC,OAAI,SAAS,UAAU,KAAA,EACrB,cAAa,KAAK,QAAQ,SAAS;;GAGvC;AAEF,QAAO"}
|
package/package.json
ADDED
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@glion/annotate-profile-datatypes",
|
|
3
|
+
"version": "0.14.1",
|
|
4
|
+
"description": "Unified plugin to annotate HL7v2 field repetition, component, and subcomponent nodes with datatype profile metadata",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"annotate",
|
|
7
|
+
"datatype",
|
|
8
|
+
"health",
|
|
9
|
+
"healthcare",
|
|
10
|
+
"hl7",
|
|
11
|
+
"hl7v2",
|
|
12
|
+
"nodejs",
|
|
13
|
+
"plugin",
|
|
14
|
+
"profile",
|
|
15
|
+
"typescript",
|
|
16
|
+
"unified"
|
|
17
|
+
],
|
|
18
|
+
"homepage": "https://glion.dev",
|
|
19
|
+
"license": "MIT",
|
|
20
|
+
"author": {
|
|
21
|
+
"name": "Melek Somai",
|
|
22
|
+
"email": "melek@rethinkhealth.io"
|
|
23
|
+
},
|
|
24
|
+
"repository": "rethinkhealth/glion.git",
|
|
25
|
+
"files": [
|
|
26
|
+
"dist"
|
|
27
|
+
],
|
|
28
|
+
"type": "module",
|
|
29
|
+
"types": "./dist/index.d.ts",
|
|
30
|
+
"exports": {
|
|
31
|
+
".": "./dist/index.js"
|
|
32
|
+
},
|
|
33
|
+
"publishConfig": {
|
|
34
|
+
"access": "public"
|
|
35
|
+
},
|
|
36
|
+
"dependencies": {
|
|
37
|
+
"unified": "11.0.5",
|
|
38
|
+
"vfile": "6.0.3",
|
|
39
|
+
"@glion/ast": "0.14.1",
|
|
40
|
+
"@glion/util-visit": "0.14.1"
|
|
41
|
+
},
|
|
42
|
+
"devDependencies": {
|
|
43
|
+
"@types/node": "^25.5.0",
|
|
44
|
+
"@vitest/coverage-v8": "4.1.2",
|
|
45
|
+
"tsdown": "0.21.7",
|
|
46
|
+
"typescript": "^5.9.3",
|
|
47
|
+
"vitest": "4.1.2",
|
|
48
|
+
"@glion/annotate-profile-context": "0.14.1",
|
|
49
|
+
"@glion/testing": "0.0.2",
|
|
50
|
+
"@glion/builder": "0.14.1",
|
|
51
|
+
"@glion/tsconfig": "0.0.1",
|
|
52
|
+
"@glion/annotate-profile-fields": "0.14.1"
|
|
53
|
+
},
|
|
54
|
+
"engines": {
|
|
55
|
+
"node": ">=18"
|
|
56
|
+
},
|
|
57
|
+
"scripts": {
|
|
58
|
+
"build": "tsdown && tsc --emitDeclarationOnly",
|
|
59
|
+
"check-types": "tsc --noEmit",
|
|
60
|
+
"bench": "vitest bench --run",
|
|
61
|
+
"test": "vitest run",
|
|
62
|
+
"test:coverage": "vitest run --coverage",
|
|
63
|
+
"test:watch": "vitest"
|
|
64
|
+
}
|
|
65
|
+
}
|