@powerlines/deepkit 0.6.167 → 0.7.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.
Files changed (138) hide show
  1. package/bin/deepkit-install.cjs +55 -90
  2. package/dist/capnp-BLx1WTBU.cjs +5175 -0
  3. package/dist/capnp-BiGNkOmV.mjs +4905 -0
  4. package/dist/capnp.cjs +47 -186
  5. package/dist/capnp.d.cts +78 -77
  6. package/dist/{capnp.d.ts → capnp.d.mts} +78 -77
  7. package/dist/capnp.mjs +3 -0
  8. package/dist/chunk-C0xms8kb.cjs +34 -0
  9. package/dist/esbuild-plugin.cjs +47 -11
  10. package/dist/esbuild-plugin.d.cts +20 -18
  11. package/dist/esbuild-plugin.d.mts +35 -0
  12. package/dist/esbuild-plugin.mjs +48 -0
  13. package/dist/index.cjs +69 -250
  14. package/dist/index.d.cts +10 -19
  15. package/dist/index.d.mts +10 -0
  16. package/dist/index.mjs +11 -0
  17. package/dist/reflect-type.cjs +24 -12
  18. package/dist/reflect-type.d.cts +7 -5
  19. package/dist/{reflect-type.d.ts → reflect-type.d.mts} +7 -5
  20. package/dist/reflect-type.mjs +24 -0
  21. package/dist/{reflection-9KUpjPqV.d.cts → reflection-BwdnCwaK.d.cts} +11 -17
  22. package/dist/{reflection-9KUpjPqV.d.ts → reflection-Chr4fE0i.d.mts} +11 -17
  23. package/dist/reflection-D9R8cdSo.d.mts +1561 -0
  24. package/dist/resolve-reflections.cjs +15 -9
  25. package/dist/resolve-reflections.d.cts +4 -2
  26. package/dist/{resolve-reflections.d.ts → resolve-reflections.d.mts} +4 -2
  27. package/dist/resolve-reflections.mjs +16 -0
  28. package/dist/rolldown-plugin.cjs +44 -11
  29. package/dist/rolldown-plugin.d.cts +5 -3
  30. package/dist/{rolldown-plugin.d.ts → rolldown-plugin.d.mts} +5 -3
  31. package/dist/rolldown-plugin.mjs +45 -0
  32. package/dist/transformer.cjs +52 -13
  33. package/dist/transformer.d.cts +6 -4
  34. package/dist/{transformer.d.ts → transformer.d.mts} +6 -4
  35. package/dist/transformer.mjs +51 -0
  36. package/dist/transpile.cjs +29 -10
  37. package/dist/transpile.d.cts +6 -4
  38. package/dist/{transpile.d.ts → transpile.d.mts} +6 -4
  39. package/dist/transpile.mjs +29 -0
  40. package/dist/types.cjs +0 -4
  41. package/dist/types.d.cts +9 -9
  42. package/dist/{types.d.ts → types.d.mts} +9 -9
  43. package/dist/types.mjs +1 -0
  44. package/dist/utilities.cjs +116 -33
  45. package/dist/utilities.d.cts +4 -2
  46. package/dist/{utilities.d.ts → utilities.d.mts} +4 -2
  47. package/dist/utilities.mjs +111 -0
  48. package/dist/vendor/core.cjs +1240 -513
  49. package/dist/vendor/core.mjs +1116 -0
  50. package/dist/vendor/string-BoXo0wS7.cjs +2983 -0
  51. package/dist/vendor/string-BuMgdahD.mjs +2467 -0
  52. package/dist/vendor/type-BMLjRtLY.cjs +202 -0
  53. package/dist/vendor/type-Dgeqs-rL.mjs +190 -0
  54. package/dist/vendor/type-compiler/compiler-BUrWMhGi.cjs +6792 -0
  55. package/dist/vendor/type-compiler/compiler-Bg8jX6qU.mjs +6739 -0
  56. package/dist/vendor/type-compiler/compiler-D1z5h1MK.d.cts +578 -0
  57. package/dist/vendor/type-compiler/compiler-Nkxc4PLJ.d.mts +578 -0
  58. package/dist/vendor/type-compiler/compiler.cjs +11 -43
  59. package/dist/vendor/type-compiler/compiler.d.cts +2 -3
  60. package/dist/vendor/type-compiler/compiler.d.mts +2 -0
  61. package/dist/vendor/type-compiler/compiler.mjs +3 -0
  62. package/dist/vendor/type-compiler/config-BEX924PC.cjs +3709 -0
  63. package/dist/vendor/type-compiler/config-B_cKkYZm.d.cts +116 -0
  64. package/dist/vendor/type-compiler/config-D9DM7Du_.d.mts +116 -0
  65. package/dist/vendor/type-compiler/config-y0HNkbCH.mjs +3640 -0
  66. package/dist/vendor/type-compiler/config.cjs +9 -34
  67. package/dist/vendor/type-compiler/config.d.cts +2 -1
  68. package/dist/vendor/type-compiler/config.d.mts +2 -0
  69. package/dist/vendor/type-compiler/config.mjs +3 -0
  70. package/dist/vendor/type-compiler/index.cjs +56 -129
  71. package/dist/vendor/type-compiler/index.d.cts +22 -3
  72. package/dist/vendor/type-compiler/index.d.mts +22 -0
  73. package/dist/vendor/type-compiler/index.mjs +50 -0
  74. package/dist/vendor/type-spec.cjs +11 -12
  75. package/dist/vendor/type-spec.mjs +3 -0
  76. package/dist/vendor/type.cjs +8407 -17892
  77. package/dist/vendor/type.d.cts +10 -196
  78. package/dist/vendor/{type.d.ts → type.d.mts} +10 -196
  79. package/dist/vendor/type.mjs +9109 -0
  80. package/package.json +43 -31
  81. package/schemas/reflection.cjs +4018 -4129
  82. package/schemas/reflection.d.cts +30 -38
  83. package/schemas/{reflection.d.ts → reflection.d.mts} +30 -38
  84. package/schemas/reflection.mjs +4036 -0
  85. package/dist/capnp.js +0 -2
  86. package/dist/chunk-23YNDVRG.js +0 -34
  87. package/dist/chunk-27RKMKSF.cjs +0 -50
  88. package/dist/chunk-2XDQUCXZ.js +0 -2392
  89. package/dist/chunk-34OFD7LS.cjs +0 -68
  90. package/dist/chunk-7FXYDYVQ.cjs +0 -5246
  91. package/dist/chunk-7QZGCBH7.cjs +0 -11
  92. package/dist/chunk-ALM6UMVU.js +0 -9
  93. package/dist/chunk-BLLXF42T.cjs +0 -41
  94. package/dist/chunk-H3Q3XL3D.js +0 -19
  95. package/dist/chunk-HPVJ6OV3.cjs +0 -31
  96. package/dist/chunk-JQUKKAFM.js +0 -48
  97. package/dist/chunk-KK7TQA7L.cjs +0 -25
  98. package/dist/chunk-NPV2346T.js +0 -25
  99. package/dist/chunk-ORA4UQMU.cjs +0 -2
  100. package/dist/chunk-OUGDFUKJ.cjs +0 -2400
  101. package/dist/chunk-OULCUN6I.js +0 -1
  102. package/dist/chunk-SHUYVCID.js +0 -4
  103. package/dist/chunk-TDYIUJGY.js +0 -5180
  104. package/dist/chunk-USNT2KNT.cjs +0 -6
  105. package/dist/chunk-WYEFKIRL.js +0 -66
  106. package/dist/esbuild-plugin.d.ts +0 -33
  107. package/dist/esbuild-plugin.js +0 -4
  108. package/dist/index.d.ts +0 -19
  109. package/dist/index.js +0 -10
  110. package/dist/reflect-type.js +0 -5
  111. package/dist/resolve-reflections.js +0 -2
  112. package/dist/rolldown-plugin.js +0 -4
  113. package/dist/transformer.js +0 -2
  114. package/dist/transpile.js +0 -3
  115. package/dist/types.js +0 -1
  116. package/dist/utilities.js +0 -2
  117. package/dist/vendor/chunk-5BKT4CS5.js +0 -28
  118. package/dist/vendor/chunk-BLN7QVCP.js +0 -3704
  119. package/dist/vendor/chunk-BR2FK5K7.js +0 -109
  120. package/dist/vendor/chunk-EPQZMVJO.cjs +0 -3859
  121. package/dist/vendor/chunk-IFK6AU6M.cjs +0 -42
  122. package/dist/vendor/chunk-SHDAXCXF.cjs +0 -115
  123. package/dist/vendor/core.js +0 -2
  124. package/dist/vendor/type-compiler/chunk-3LL3TSRJ.js +0 -3762
  125. package/dist/vendor/type-compiler/chunk-CUTGHVNY.js +0 -7100
  126. package/dist/vendor/type-compiler/chunk-IAWCLVUK.cjs +0 -3780
  127. package/dist/vendor/type-compiler/chunk-UIWPG352.cjs +0 -7114
  128. package/dist/vendor/type-compiler/compiler.d.ts +0 -3
  129. package/dist/vendor/type-compiler/compiler.js +0 -5
  130. package/dist/vendor/type-compiler/config.d.ts +0 -1
  131. package/dist/vendor/type-compiler/config.js +0 -5
  132. package/dist/vendor/type-compiler/index.d.ts +0 -3
  133. package/dist/vendor/type-compiler/index.js +0 -66
  134. package/dist/vendor/type-spec.js +0 -2
  135. package/dist/vendor/type.js +0 -18359
  136. package/schemas/reflection.js +0 -4153
  137. /package/dist/vendor/{core.d.ts → core.d.mts} +0 -0
  138. /package/dist/vendor/{type-spec.d.ts → type-spec.d.mts} +0 -0
@@ -0,0 +1,116 @@
1
+ import ts, { CompilerOptions, ParseConfigHost } from "typescript";
2
+
3
+ //#region ../../node_modules/.pnpm/@deepkit+type-compiler@1.0.5_patch_hash=439aa6e683a9a48c3ebbf3529be5811680c45c22d6a265d_be73b50bc43bac944747b8ca0498113a/node_modules/@deepkit/type-compiler/dist/cjs/src/config.d.ts
4
+ /**
5
+ * Default means reflection is enabled for this file.
6
+ * Never means the whole reflection is disabled for this file.
7
+ * Explicit means that reflection is per default disabled for this file, but each symbol/type
8
+ * in it is allowed to enable it using jsdoc `@reflection`.
9
+ */
10
+ declare const reflectionModes: readonly ["default", "explicit", "never"];
11
+ type Mode = (typeof reflectionModes)[number];
12
+ type RawMode = Mode | "" | boolean | string | string[] | undefined;
13
+ declare function isObject(obj: any): obj is {
14
+ [key: string]: any;
15
+ };
16
+ declare const reflectionLevel: string[];
17
+ type Level = (typeof reflectionLevel)[number];
18
+ /**
19
+ * These are the values that can be in the tsconfig.json file.
20
+ */
21
+ interface TsConfigJson {
22
+ extends?: string;
23
+ compilerOptions?: any;
24
+ reflection?: RawMode;
25
+ /**
26
+ * Defines the level of reflection to be used during the transpilation process.
27
+ *
28
+ * @remarks
29
+ * The level determines how much extra data is captured in the byte code for each type. This can be one of the following values:
30
+ * - `minimal` - Only the essential type information is captured. (only "hidden", "ignore" and "internal", "readonly")
31
+ * - `normal` - Additional type information is captured, including some contextual data. (adds "alias" and "runtime")
32
+ * - `extended` - Even more detailed type information is captured, including extended contextual data. (adds "permissions" and "domain")
33
+ * - `verbose` - All available type information is captured, including detailed contextual data. (adds "title" and "description")
34
+ */
35
+ reflectionLevel?: Level;
36
+ deepkitCompilerOptions?: {
37
+ /**
38
+ * Either true to activate reflection for all files compiled using this tsconfig,
39
+ * or a list of globs/file paths relative to this tsconfig.json.
40
+ * Globs/file paths can be prefixed with a ! to exclude them.
41
+ */
42
+ reflection?: RawMode;
43
+ /**
44
+ * Defines the level of reflection to be used during the transpilation process.
45
+ *
46
+ * @remarks
47
+ * The level determines how much extra data is captured in the byte code for each type. This can be one of the following values:
48
+ * - `minimal` - Only the essential type information is captured.
49
+ * - `normal` - Additional type information is captured, including some contextual data.
50
+ * - `verbose` - All available type information is captured, including detailed contextual data.
51
+ */
52
+ reflectionLevel?: Level;
53
+ /**
54
+ * If a tsconfig extends another tsconfig, this option defines how the reflection/exclude
55
+ * options are merged. The default strategy is `merge`, which means that the reflection/exclude
56
+ * options are merged with the parent tsconfig.json. If set to `replace`, the reflection/exclude
57
+ * options are not merged, but the parent tsconfig.json is ignored.
58
+ */
59
+ mergeStrategy?: "merge" | "replace";
60
+ /**
61
+ * List of globs/file paths relative to this tsconfig.json
62
+ * which are then excluded from the type compilation step.
63
+ * Per default a few global .d.ts files are excluded like `lib.dom*.d.ts` and `*typedarrays.d.ts`.
64
+ */
65
+ exclude?: string[];
66
+ };
67
+ }
68
+ interface ReflectionConfig {
69
+ /**
70
+ * Allows to exclude type definitions/TS files from being included in the type compilation step.
71
+ * When a global .d.ts is matched, their types won't be embedded (useful to exclude DOM for example)
72
+ */
73
+ exclude?: string[];
74
+ /**
75
+ * Either a boolean indication general reflection mode,
76
+ * or a list of globs to match against.
77
+ */
78
+ reflection?: string[] | Mode;
79
+ /**
80
+ * Defines the level of reflection to be used during the transpilation process.
81
+ */
82
+ reflectionLevel?: Level;
83
+ }
84
+ interface CurrentConfig extends ReflectionConfig {
85
+ compilerOptions: ts.CompilerOptions;
86
+ mergeStrategy?: "merge" | "replace";
87
+ extends?: string;
88
+ }
89
+ interface ResolvedConfig extends ReflectionConfig {
90
+ path: string;
91
+ compilerOptions: ts.CompilerOptions;
92
+ mergeStrategy: "merge" | "replace";
93
+ reflectionLevel: Level;
94
+ }
95
+ declare function reflectionModeMatcher(config: ReflectionConfig, filePath: string): Mode;
96
+ declare function parseRawMode(mode: RawMode): string[] | Mode;
97
+ interface MatchResult {
98
+ tsConfigPath: string;
99
+ mode: (typeof reflectionModes)[number];
100
+ level: (typeof reflectionLevel)[number];
101
+ }
102
+ declare const defaultExcluded: string[];
103
+ type Matcher = (path: string) => MatchResult;
104
+ type ConfigResolver = {
105
+ match: Matcher;
106
+ config: ResolvedConfig;
107
+ };
108
+ type ReflectionConfigCache = {
109
+ [path: string]: ConfigResolver;
110
+ };
111
+ declare function getConfigResolver(cache: ReflectionConfigCache, host: ParseConfigHost, compilerOptions: CompilerOptions, sourceFile: {
112
+ fileName: string;
113
+ }, tsConfigPath?: string): ConfigResolver;
114
+ //#endregion
115
+ export { reflectionModeMatcher as _, Matcher as a, ReflectionConfig as c, TsConfigJson as d, defaultExcluded as f, reflectionLevel as g, parseRawMode as h, MatchResult as i, ReflectionConfigCache as l, isObject as m, CurrentConfig as n, Mode as o, getConfigResolver as p, Level as r, RawMode as s, ConfigResolver as t, ResolvedConfig as u, reflectionModes as v };
116
+ //# sourceMappingURL=config-B_cKkYZm.d.cts.map
@@ -0,0 +1,116 @@
1
+ import ts, { CompilerOptions, ParseConfigHost } from "typescript";
2
+
3
+ //#region ../../node_modules/.pnpm/@deepkit+type-compiler@1.0.5_patch_hash=439aa6e683a9a48c3ebbf3529be5811680c45c22d6a265d_be73b50bc43bac944747b8ca0498113a/node_modules/@deepkit/type-compiler/dist/cjs/src/config.d.ts
4
+ /**
5
+ * Default means reflection is enabled for this file.
6
+ * Never means the whole reflection is disabled for this file.
7
+ * Explicit means that reflection is per default disabled for this file, but each symbol/type
8
+ * in it is allowed to enable it using jsdoc `@reflection`.
9
+ */
10
+ declare const reflectionModes: readonly ["default", "explicit", "never"];
11
+ type Mode = (typeof reflectionModes)[number];
12
+ type RawMode = Mode | "" | boolean | string | string[] | undefined;
13
+ declare function isObject(obj: any): obj is {
14
+ [key: string]: any;
15
+ };
16
+ declare const reflectionLevel: string[];
17
+ type Level = (typeof reflectionLevel)[number];
18
+ /**
19
+ * These are the values that can be in the tsconfig.json file.
20
+ */
21
+ interface TsConfigJson {
22
+ extends?: string;
23
+ compilerOptions?: any;
24
+ reflection?: RawMode;
25
+ /**
26
+ * Defines the level of reflection to be used during the transpilation process.
27
+ *
28
+ * @remarks
29
+ * The level determines how much extra data is captured in the byte code for each type. This can be one of the following values:
30
+ * - `minimal` - Only the essential type information is captured. (only "hidden", "ignore" and "internal", "readonly")
31
+ * - `normal` - Additional type information is captured, including some contextual data. (adds "alias" and "runtime")
32
+ * - `extended` - Even more detailed type information is captured, including extended contextual data. (adds "permissions" and "domain")
33
+ * - `verbose` - All available type information is captured, including detailed contextual data. (adds "title" and "description")
34
+ */
35
+ reflectionLevel?: Level;
36
+ deepkitCompilerOptions?: {
37
+ /**
38
+ * Either true to activate reflection for all files compiled using this tsconfig,
39
+ * or a list of globs/file paths relative to this tsconfig.json.
40
+ * Globs/file paths can be prefixed with a ! to exclude them.
41
+ */
42
+ reflection?: RawMode;
43
+ /**
44
+ * Defines the level of reflection to be used during the transpilation process.
45
+ *
46
+ * @remarks
47
+ * The level determines how much extra data is captured in the byte code for each type. This can be one of the following values:
48
+ * - `minimal` - Only the essential type information is captured.
49
+ * - `normal` - Additional type information is captured, including some contextual data.
50
+ * - `verbose` - All available type information is captured, including detailed contextual data.
51
+ */
52
+ reflectionLevel?: Level;
53
+ /**
54
+ * If a tsconfig extends another tsconfig, this option defines how the reflection/exclude
55
+ * options are merged. The default strategy is `merge`, which means that the reflection/exclude
56
+ * options are merged with the parent tsconfig.json. If set to `replace`, the reflection/exclude
57
+ * options are not merged, but the parent tsconfig.json is ignored.
58
+ */
59
+ mergeStrategy?: "merge" | "replace";
60
+ /**
61
+ * List of globs/file paths relative to this tsconfig.json
62
+ * which are then excluded from the type compilation step.
63
+ * Per default a few global .d.ts files are excluded like `lib.dom*.d.ts` and `*typedarrays.d.ts`.
64
+ */
65
+ exclude?: string[];
66
+ };
67
+ }
68
+ interface ReflectionConfig {
69
+ /**
70
+ * Allows to exclude type definitions/TS files from being included in the type compilation step.
71
+ * When a global .d.ts is matched, their types won't be embedded (useful to exclude DOM for example)
72
+ */
73
+ exclude?: string[];
74
+ /**
75
+ * Either a boolean indication general reflection mode,
76
+ * or a list of globs to match against.
77
+ */
78
+ reflection?: string[] | Mode;
79
+ /**
80
+ * Defines the level of reflection to be used during the transpilation process.
81
+ */
82
+ reflectionLevel?: Level;
83
+ }
84
+ interface CurrentConfig extends ReflectionConfig {
85
+ compilerOptions: ts.CompilerOptions;
86
+ mergeStrategy?: "merge" | "replace";
87
+ extends?: string;
88
+ }
89
+ interface ResolvedConfig extends ReflectionConfig {
90
+ path: string;
91
+ compilerOptions: ts.CompilerOptions;
92
+ mergeStrategy: "merge" | "replace";
93
+ reflectionLevel: Level;
94
+ }
95
+ declare function reflectionModeMatcher(config: ReflectionConfig, filePath: string): Mode;
96
+ declare function parseRawMode(mode: RawMode): string[] | Mode;
97
+ interface MatchResult {
98
+ tsConfigPath: string;
99
+ mode: (typeof reflectionModes)[number];
100
+ level: (typeof reflectionLevel)[number];
101
+ }
102
+ declare const defaultExcluded: string[];
103
+ type Matcher = (path: string) => MatchResult;
104
+ type ConfigResolver = {
105
+ match: Matcher;
106
+ config: ResolvedConfig;
107
+ };
108
+ type ReflectionConfigCache = {
109
+ [path: string]: ConfigResolver;
110
+ };
111
+ declare function getConfigResolver(cache: ReflectionConfigCache, host: ParseConfigHost, compilerOptions: CompilerOptions, sourceFile: {
112
+ fileName: string;
113
+ }, tsConfigPath?: string): ConfigResolver;
114
+ //#endregion
115
+ export { reflectionModeMatcher as _, Matcher as a, ReflectionConfig as c, TsConfigJson as d, defaultExcluded as f, reflectionLevel as g, parseRawMode as h, MatchResult as i, ReflectionConfigCache as l, isObject as m, CurrentConfig as n, Mode as o, getConfigResolver as p, Level as r, RawMode as s, ConfigResolver as t, ResolvedConfig as u, reflectionModes as v };
116
+ //# sourceMappingURL=config-D9DM7Du_.d.mts.map