@powerlines/plugin-env 0.13.16 → 0.13.18

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.
@@ -1,5 +1,5 @@
1
1
  export { envBabelPlugin } from './plugin.cjs';
2
- import '../runtime-DsoL32bv.cjs';
2
+ import '../runtime-CXFOdIeH.cjs';
3
3
  import '@stryke/env/get-env-paths';
4
4
  import '@stryke/types/base';
5
5
  import '@stryke/types/package-json';
@@ -18,11 +18,9 @@ import '@babel/helper-plugin-utils';
18
18
  import '@stryke/types/array';
19
19
  import '@stryke/types/tsconfig';
20
20
  import 'typescript';
21
- import '../vfs-Bl84Hw2V.cjs';
21
+ import '../vfs-BGmsy47f.cjs';
22
22
  import '@stryke/json/types';
23
- import 'memfs';
24
23
  import 'node:fs';
25
- import 'unionfs';
26
24
  import '../types/plugin.cjs';
27
25
  import '@alloy-js/core/jsx-runtime';
28
26
  import '@deepkit/type';
@@ -1,5 +1,5 @@
1
1
  export { envBabelPlugin } from './plugin.js';
2
- import '../runtime-DEVUXRrw.js';
2
+ import '../runtime-BZR8Re97.js';
3
3
  import '@stryke/env/get-env-paths';
4
4
  import '@stryke/types/base';
5
5
  import '@stryke/types/package-json';
@@ -18,11 +18,9 @@ import '@babel/helper-plugin-utils';
18
18
  import '@stryke/types/array';
19
19
  import '@stryke/types/tsconfig';
20
20
  import 'typescript';
21
- import '../vfs-Bl84Hw2V.js';
21
+ import '../vfs-BGmsy47f.js';
22
22
  import '@stryke/json/types';
23
- import 'memfs';
24
23
  import 'node:fs';
25
- import 'unionfs';
26
24
  import '../types/plugin.js';
27
25
  import '@alloy-js/core/jsx-runtime';
28
26
  import '@deepkit/type';
@@ -1,4 +1,4 @@
1
- import { D as DeclareBabelTransformPluginReturn } from '../runtime-DsoL32bv.cjs';
1
+ import { D as DeclareBabelTransformPluginReturn } from '../runtime-CXFOdIeH.cjs';
2
2
  import { EnvPluginContext, EnvPluginResolvedConfig } from '../types/plugin.cjs';
3
3
  import '@stryke/env/get-env-paths';
4
4
  import '@stryke/types/base';
@@ -18,11 +18,9 @@ import '@babel/helper-plugin-utils';
18
18
  import '@stryke/types/array';
19
19
  import '@stryke/types/tsconfig';
20
20
  import 'typescript';
21
- import '../vfs-Bl84Hw2V.cjs';
21
+ import '../vfs-BGmsy47f.cjs';
22
22
  import '@stryke/json/types';
23
- import 'memfs';
24
23
  import 'node:fs';
25
- import 'unionfs';
26
24
  import '@alloy-js/core/jsx-runtime';
27
25
  import '@deepkit/type';
28
26
  import '@stryke/capnp';
@@ -1,4 +1,4 @@
1
- import { D as DeclareBabelTransformPluginReturn } from '../runtime-DEVUXRrw.js';
1
+ import { D as DeclareBabelTransformPluginReturn } from '../runtime-BZR8Re97.js';
2
2
  import { EnvPluginContext, EnvPluginResolvedConfig } from '../types/plugin.js';
3
3
  import '@stryke/env/get-env-paths';
4
4
  import '@stryke/types/base';
@@ -18,11 +18,9 @@ import '@babel/helper-plugin-utils';
18
18
  import '@stryke/types/array';
19
19
  import '@stryke/types/tsconfig';
20
20
  import 'typescript';
21
- import '../vfs-Bl84Hw2V.js';
21
+ import '../vfs-BGmsy47f.js';
22
22
  import '@stryke/json/types';
23
- import 'memfs';
24
23
  import 'node:fs';
25
- import 'unionfs';
26
24
  import '@alloy-js/core/jsx-runtime';
27
25
  import '@deepkit/type';
28
26
  import '@stryke/capnp';
@@ -1,12 +1,10 @@
1
1
  import { Children as Children$1, SourceFileProps as SourceFileProps$1 } from '@alloy-js/core';
2
2
  import { Children } from '@alloy-js/core/jsx-runtime';
3
- import { O as OutputModeType } from '../vfs-Bl84Hw2V.cjs';
3
+ import { O as OutputModeType } from '../vfs-BGmsy47f.cjs';
4
4
  import { InterfaceDeclarationProps } from '@alloy-js/typescript';
5
5
  import { ReflectionClass } from '@deepkit/type';
6
6
  import '@stryke/json/types';
7
- import 'memfs';
8
7
  import 'node:fs';
9
- import 'unionfs';
10
8
 
11
9
  /**
12
10
  * A type that represents the props of a component that can have children.
@@ -1,12 +1,10 @@
1
1
  import { Children as Children$1, SourceFileProps as SourceFileProps$1 } from '@alloy-js/core';
2
2
  import { Children } from '@alloy-js/core/jsx-runtime';
3
- import { O as OutputModeType } from '../vfs-Bl84Hw2V.js';
3
+ import { O as OutputModeType } from '../vfs-BGmsy47f.js';
4
4
  import { InterfaceDeclarationProps } from '@alloy-js/typescript';
5
5
  import { ReflectionClass } from '@deepkit/type';
6
6
  import '@stryke/json/types';
7
- import 'memfs';
8
7
  import 'node:fs';
9
- import 'unionfs';
10
8
 
11
9
  /**
12
10
  * A type that represents the props of a component that can have children.
@@ -1,10 +1,8 @@
1
1
  export { EnvBuiltin, EnvBuiltinProps, EnvTypeDefinition } from './env.cjs';
2
2
  import '@alloy-js/core';
3
3
  import '@alloy-js/core/jsx-runtime';
4
- import '../vfs-Bl84Hw2V.cjs';
4
+ import '../vfs-BGmsy47f.cjs';
5
5
  import '@stryke/json/types';
6
- import 'memfs';
7
6
  import 'node:fs';
8
- import 'unionfs';
9
7
  import '@alloy-js/typescript';
10
8
  import '@deepkit/type';
@@ -1,10 +1,8 @@
1
1
  export { EnvBuiltin, EnvBuiltinProps, EnvTypeDefinition } from './env.js';
2
2
  import '@alloy-js/core';
3
3
  import '@alloy-js/core/jsx-runtime';
4
- import '../vfs-Bl84Hw2V.js';
4
+ import '../vfs-BGmsy47f.js';
5
5
  import '@stryke/json/types';
6
- import 'memfs';
7
6
  import 'node:fs';
8
- import 'unionfs';
9
7
  import '@alloy-js/typescript';
10
8
  import '@deepkit/type';
@@ -3,7 +3,7 @@ export { getEnvDefaultTypeDefinition, getEnvReflectionsPath, getEnvTypeReflectio
3
3
  export { BaseEnv, BaseSecrets, CreateEnvReflectionOptions, createEnvReflection, createSecretsReflection, mergeEnvReflections, mergeSecretsReflections, reflectEnv, reflectSecrets } from './reflect.cjs';
4
4
  export { formatEnvField, removeEnvPrefix } from './source-file-env.cjs';
5
5
  export { createTemplateReflection } from './template-helpers.cjs';
6
- import '../runtime-DsoL32bv.cjs';
6
+ import '../runtime-CXFOdIeH.cjs';
7
7
  import '@stryke/env/get-env-paths';
8
8
  import '@stryke/types/base';
9
9
  import '@stryke/types/package-json';
@@ -22,11 +22,9 @@ import '@babel/helper-plugin-utils';
22
22
  import '@stryke/types/array';
23
23
  import '@stryke/types/tsconfig';
24
24
  import 'typescript';
25
- import '../vfs-Bl84Hw2V.cjs';
25
+ import '../vfs-BGmsy47f.cjs';
26
26
  import '@stryke/json/types';
27
- import 'memfs';
28
27
  import 'node:fs';
29
- import 'unionfs';
30
28
  import '@stryke/env/types';
31
29
  import '../types/plugin.cjs';
32
30
  import '@alloy-js/core/jsx-runtime';
@@ -3,7 +3,7 @@ export { getEnvDefaultTypeDefinition, getEnvReflectionsPath, getEnvTypeReflectio
3
3
  export { BaseEnv, BaseSecrets, CreateEnvReflectionOptions, createEnvReflection, createSecretsReflection, mergeEnvReflections, mergeSecretsReflections, reflectEnv, reflectSecrets } from './reflect.js';
4
4
  export { formatEnvField, removeEnvPrefix } from './source-file-env.js';
5
5
  export { createTemplateReflection } from './template-helpers.js';
6
- import '../runtime-DEVUXRrw.js';
6
+ import '../runtime-BZR8Re97.js';
7
7
  import '@stryke/env/get-env-paths';
8
8
  import '@stryke/types/base';
9
9
  import '@stryke/types/package-json';
@@ -22,11 +22,9 @@ import '@babel/helper-plugin-utils';
22
22
  import '@stryke/types/array';
23
23
  import '@stryke/types/tsconfig';
24
24
  import 'typescript';
25
- import '../vfs-Bl84Hw2V.js';
25
+ import '../vfs-BGmsy47f.js';
26
26
  import '@stryke/json/types';
27
- import 'memfs';
28
27
  import 'node:fs';
29
- import 'unionfs';
30
28
  import '@stryke/env/types';
31
29
  import '../types/plugin.js';
32
30
  import '@alloy-js/core/jsx-runtime';
@@ -1,4 +1,4 @@
1
- import { a as EnvironmentResolvedConfig } from '../runtime-DsoL32bv.cjs';
1
+ import { a as EnvironmentResolvedConfig } from '../runtime-CXFOdIeH.cjs';
2
2
  import { DotenvParseOutput } from '@stryke/env/types';
3
3
  import { EnvPluginContext, EnvPluginOptions } from '../types/plugin.cjs';
4
4
  import '@stryke/env/get-env-paths';
@@ -19,11 +19,9 @@ import '@babel/helper-plugin-utils';
19
19
  import '@stryke/types/array';
20
20
  import '@stryke/types/tsconfig';
21
21
  import 'typescript';
22
- import '../vfs-Bl84Hw2V.cjs';
22
+ import '../vfs-BGmsy47f.cjs';
23
23
  import '@stryke/json/types';
24
- import 'memfs';
25
24
  import 'node:fs';
26
- import 'unionfs';
27
25
  import '@alloy-js/core/jsx-runtime';
28
26
  import '@deepkit/type';
29
27
  import '@stryke/capnp';
@@ -1,4 +1,4 @@
1
- import { a as EnvironmentResolvedConfig } from '../runtime-DEVUXRrw.js';
1
+ import { a as EnvironmentResolvedConfig } from '../runtime-BZR8Re97.js';
2
2
  import { DotenvParseOutput } from '@stryke/env/types';
3
3
  import { EnvPluginContext, EnvPluginOptions } from '../types/plugin.js';
4
4
  import '@stryke/env/get-env-paths';
@@ -19,11 +19,9 @@ import '@babel/helper-plugin-utils';
19
19
  import '@stryke/types/array';
20
20
  import '@stryke/types/tsconfig';
21
21
  import 'typescript';
22
- import '../vfs-Bl84Hw2V.js';
22
+ import '../vfs-BGmsy47f.js';
23
23
  import '@stryke/json/types';
24
- import 'memfs';
25
24
  import 'node:fs';
26
- import 'unionfs';
27
25
  import '@alloy-js/core/jsx-runtime';
28
26
  import '@deepkit/type';
29
27
  import '@stryke/capnp';
@@ -1,6 +1,6 @@
1
1
  import { ReflectionClass } from '@deepkit/type';
2
2
  import { TypeDefinition } from '@stryke/types/configuration';
3
- import { U as UnresolvedContext, C as Context } from '../runtime-DsoL32bv.cjs';
3
+ import { U as UnresolvedContext, C as Context } from '../runtime-CXFOdIeH.cjs';
4
4
  import { EnvPluginResolvedConfig, EnvType, EnvPluginContext } from '../types/plugin.cjs';
5
5
  import '@stryke/env/get-env-paths';
6
6
  import '@stryke/types/base';
@@ -19,11 +19,9 @@ import '@babel/helper-plugin-utils';
19
19
  import '@stryke/types/array';
20
20
  import '@stryke/types/tsconfig';
21
21
  import 'typescript';
22
- import '../vfs-Bl84Hw2V.cjs';
22
+ import '../vfs-BGmsy47f.cjs';
23
23
  import '@stryke/json/types';
24
- import 'memfs';
25
24
  import 'node:fs';
26
- import 'unionfs';
27
25
  import '@alloy-js/core/jsx-runtime';
28
26
  import '@stryke/capnp';
29
27
  import '@stryke/env/types';
@@ -1,6 +1,6 @@
1
1
  import { ReflectionClass } from '@deepkit/type';
2
2
  import { TypeDefinition } from '@stryke/types/configuration';
3
- import { U as UnresolvedContext, C as Context } from '../runtime-DEVUXRrw.js';
3
+ import { U as UnresolvedContext, C as Context } from '../runtime-BZR8Re97.js';
4
4
  import { EnvPluginResolvedConfig, EnvType, EnvPluginContext } from '../types/plugin.js';
5
5
  import '@stryke/env/get-env-paths';
6
6
  import '@stryke/types/base';
@@ -19,11 +19,9 @@ import '@babel/helper-plugin-utils';
19
19
  import '@stryke/types/array';
20
20
  import '@stryke/types/tsconfig';
21
21
  import 'typescript';
22
- import '../vfs-Bl84Hw2V.js';
22
+ import '../vfs-BGmsy47f.js';
23
23
  import '@stryke/json/types';
24
- import 'memfs';
25
24
  import 'node:fs';
26
- import 'unionfs';
27
25
  import '@alloy-js/core/jsx-runtime';
28
26
  import '@stryke/capnp';
29
27
  import '@stryke/env/types';
@@ -1,6 +1,6 @@
1
1
  import { ReflectionClass, TypeObjectLiteral, TypeClass } from '@deepkit/type';
2
2
  import { EnvPluginContext } from '../types/plugin.cjs';
3
- import { E as EnvInterface, S as SecretsInterface } from '../runtime-DsoL32bv.cjs';
3
+ import { E as EnvInterface, S as SecretsInterface } from '../runtime-CXFOdIeH.cjs';
4
4
  import '@alloy-js/core/jsx-runtime';
5
5
  import '@stryke/capnp';
6
6
  import '@stryke/env/types';
@@ -22,11 +22,9 @@ import '@babel/helper-plugin-utils';
22
22
  import '@stryke/types/array';
23
23
  import '@stryke/types/tsconfig';
24
24
  import 'typescript';
25
- import '../vfs-Bl84Hw2V.cjs';
25
+ import '../vfs-BGmsy47f.cjs';
26
26
  import '@stryke/json/types';
27
- import 'memfs';
28
27
  import 'node:fs';
29
- import 'unionfs';
30
28
 
31
29
  declare function mergeEnvReflections(context: EnvPluginContext, reflections: ReflectionClass<any>[]): ReflectionClass<any>;
32
30
  declare function mergeSecretsReflections(context: EnvPluginContext, reflections: ReflectionClass<any>[]): ReflectionClass<any>;
@@ -1,6 +1,6 @@
1
1
  import { ReflectionClass, TypeObjectLiteral, TypeClass } from '@deepkit/type';
2
2
  import { EnvPluginContext } from '../types/plugin.js';
3
- import { E as EnvInterface, S as SecretsInterface } from '../runtime-DEVUXRrw.js';
3
+ import { E as EnvInterface, S as SecretsInterface } from '../runtime-BZR8Re97.js';
4
4
  import '@alloy-js/core/jsx-runtime';
5
5
  import '@stryke/capnp';
6
6
  import '@stryke/env/types';
@@ -22,11 +22,9 @@ import '@babel/helper-plugin-utils';
22
22
  import '@stryke/types/array';
23
23
  import '@stryke/types/tsconfig';
24
24
  import 'typescript';
25
- import '../vfs-Bl84Hw2V.js';
25
+ import '../vfs-BGmsy47f.js';
26
26
  import '@stryke/json/types';
27
- import 'memfs';
28
27
  import 'node:fs';
29
- import 'unionfs';
30
28
 
31
29
  declare function mergeEnvReflections(context: EnvPluginContext, reflections: ReflectionClass<any>[]): ReflectionClass<any>;
32
30
  declare function mergeSecretsReflections(context: EnvPluginContext, reflections: ReflectionClass<any>[]): ReflectionClass<any>;
@@ -2,7 +2,7 @@ import { ReflectionClass } from '@deepkit/type';
2
2
  import { EnvPluginContext, EnvType } from '../types/plugin.cjs';
3
3
  import '@alloy-js/core/jsx-runtime';
4
4
  import '@stryke/capnp';
5
- import '../runtime-DsoL32bv.cjs';
5
+ import '../runtime-CXFOdIeH.cjs';
6
6
  import '@stryke/env/get-env-paths';
7
7
  import '@stryke/types/base';
8
8
  import '@stryke/types/package-json';
@@ -21,11 +21,9 @@ import '@babel/helper-plugin-utils';
21
21
  import '@stryke/types/array';
22
22
  import '@stryke/types/tsconfig';
23
23
  import 'typescript';
24
- import '../vfs-Bl84Hw2V.cjs';
24
+ import '../vfs-BGmsy47f.cjs';
25
25
  import '@stryke/json/types';
26
- import 'memfs';
27
26
  import 'node:fs';
28
- import 'unionfs';
29
27
  import '@stryke/env/types';
30
28
 
31
29
  /**
@@ -2,7 +2,7 @@ import { ReflectionClass } from '@deepkit/type';
2
2
  import { EnvPluginContext, EnvType } from '../types/plugin.js';
3
3
  import '@alloy-js/core/jsx-runtime';
4
4
  import '@stryke/capnp';
5
- import '../runtime-DEVUXRrw.js';
5
+ import '../runtime-BZR8Re97.js';
6
6
  import '@stryke/env/get-env-paths';
7
7
  import '@stryke/types/base';
8
8
  import '@stryke/types/package-json';
@@ -21,11 +21,9 @@ import '@babel/helper-plugin-utils';
21
21
  import '@stryke/types/array';
22
22
  import '@stryke/types/tsconfig';
23
23
  import 'typescript';
24
- import '../vfs-Bl84Hw2V.js';
24
+ import '../vfs-BGmsy47f.js';
25
25
  import '@stryke/json/types';
26
- import 'memfs';
27
26
  import 'node:fs';
28
- import 'unionfs';
29
27
  import '@stryke/env/types';
30
28
 
31
29
  /**
package/dist/index.d.cts CHANGED
@@ -1,5 +1,5 @@
1
- import { P as PluginContext, b as Plugin } from './runtime-DsoL32bv.cjs';
2
- export { E as EnvInterface, S as SecretsInterface } from './runtime-DsoL32bv.cjs';
1
+ import { P as PluginContext, b as Plugin } from './runtime-CXFOdIeH.cjs';
2
+ export { E as EnvInterface, S as SecretsInterface } from './runtime-CXFOdIeH.cjs';
3
3
  import { Children } from '@alloy-js/core/jsx-runtime';
4
4
  import { PrintTreeOptions } from '@alloy-js/core';
5
5
  import { EnvPluginContext, EnvPluginResolvedConfig } from './types/plugin.cjs';
@@ -29,11 +29,9 @@ import '@babel/helper-plugin-utils';
29
29
  import '@stryke/types/array';
30
30
  import '@stryke/types/tsconfig';
31
31
  import 'typescript';
32
- import './vfs-Bl84Hw2V.cjs';
32
+ import './vfs-BGmsy47f.cjs';
33
33
  import '@stryke/json/types';
34
- import 'memfs';
35
34
  import 'node:fs';
36
- import 'unionfs';
37
35
  import '@deepkit/type';
38
36
  import '@stryke/capnp';
39
37
  import '@stryke/env/types';
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { P as PluginContext, b as Plugin } from './runtime-DEVUXRrw.js';
2
- export { E as EnvInterface, S as SecretsInterface } from './runtime-DEVUXRrw.js';
1
+ import { P as PluginContext, b as Plugin } from './runtime-BZR8Re97.js';
2
+ export { E as EnvInterface, S as SecretsInterface } from './runtime-BZR8Re97.js';
3
3
  import { Children } from '@alloy-js/core/jsx-runtime';
4
4
  import { PrintTreeOptions } from '@alloy-js/core';
5
5
  import { EnvPluginContext, EnvPluginResolvedConfig } from './types/plugin.js';
@@ -29,11 +29,9 @@ import '@babel/helper-plugin-utils';
29
29
  import '@stryke/types/array';
30
30
  import '@stryke/types/tsconfig';
31
31
  import 'typescript';
32
- import './vfs-Bl84Hw2V.js';
32
+ import './vfs-BGmsy47f.js';
33
33
  import '@stryke/json/types';
34
- import 'memfs';
35
34
  import 'node:fs';
36
- import 'unionfs';
37
35
  import '@deepkit/type';
38
36
  import '@stryke/capnp';
39
37
  import '@stryke/env/types';
@@ -16,7 +16,7 @@ import { BabelAPI } from '@babel/helper-plugin-utils';
16
16
  import { ArrayValues } from '@stryke/types/array';
17
17
  import { TsConfigJson, CompilerOptions } from '@stryke/types/tsconfig';
18
18
  import ts from 'typescript';
19
- import { O as OutputModeType, V as VirtualFileSystemInterface, a as VirtualFile, P as PowerlinesWriteFileOptions } from './vfs-Bl84Hw2V.js';
19
+ import { O as OutputModeType, V as VirtualFileSystemInterface, a as VirtualFile, P as PowerlinesWriteFileOptions } from './vfs-BGmsy47f.js';
20
20
 
21
21
  type BabelPluginPass<TState = unknown> = PluginPass & TState;
22
22
  type BabelTransformPluginFilter = (code: string, id: string) => boolean;
@@ -45,6 +45,20 @@ interface BuildConfig {
45
45
  * @defaultValue "neutral"
46
46
  */
47
47
  platform?: "node" | "browser" | "neutral";
48
+ /**
49
+ * Array of strings indicating the polyfills to include for the build.
50
+ *
51
+ * @remarks
52
+ * This option allows you to specify which polyfills should be included in the build process to ensure compatibility with the target environment. The paths for the polyfills can use placeholder tokens (the `replacePathTokens` helper function will be used to resolve the actual values).
53
+ *
54
+ * @example
55
+ * ```ts
56
+ * {
57
+ * polyfill: ['{projectRoot}/custom-polyfill.ts']
58
+ * }
59
+ * ```
60
+ */
61
+ polyfill?: string[];
48
62
  /**
49
63
  * Array of strings indicating the order in which fields in a package.json file should be resolved to determine the entry point for a module.
50
64
  *
@@ -130,7 +144,10 @@ interface BuildConfig {
130
144
  *
131
145
  * @see https://github.com/rollup/plugins/tree/master/packages/alias
132
146
  */
133
- alias?: Record<string, string>;
147
+ alias?: Record<string, string> | Array<{
148
+ find: string | RegExp;
149
+ replacement: string;
150
+ }>;
134
151
  /**
135
152
  * A list of modules that should not be bundled, even if they are external dependencies.
136
153
  *
@@ -156,7 +173,7 @@ interface BuildConfig {
156
173
  }
157
174
  type BuildResolvedConfig = Omit<BuildConfig, "override">;
158
175
 
159
- declare const SUPPORTED_COMMANDS: readonly ["new", "clean", "prepare", "lint", "test", "build", "docs", "release", "finalize"];
176
+ declare const SUPPORTED_COMMANDS: readonly ["new", "clean", "prepare", "lint", "test", "build", "docs", "deploy", "finalize"];
160
177
  type CommandType = ArrayValues<typeof SUPPORTED_COMMANDS>;
161
178
 
162
179
  interface ResolvedEntryTypeDefinition extends TypeDefinition {
@@ -187,7 +204,7 @@ type OutputResolvedConfig = Required<Omit<OutputConfig, "assets"> & {
187
204
  /**
188
205
  * The resolved options for the Powerlines project configuration.
189
206
  */
190
- type ResolvedConfig<TUserConfig extends UserConfig = UserConfig> = Omit<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "platform" | "tsconfig" | "lint" | "test" | "build" | "transform" | "variant" | "type" | "output" | "logLevel" | "framework"> & Required<Pick<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "tsconfig" | "lint" | "test" | "build" | "transform" | "framework">> & {
207
+ type ResolvedConfig<TUserConfig extends UserConfig = UserConfig> = Omit<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "platform" | "tsconfig" | "lint" | "test" | "build" | "transform" | "deploy" | "variant" | "type" | "output" | "logLevel" | "framework"> & Required<Pick<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "tsconfig" | "lint" | "test" | "build" | "transform" | "deploy" | "framework">> & {
191
208
  /**
192
209
  * The configuration options that were provided inline to the Powerlines CLI.
193
210
  */
@@ -689,6 +706,13 @@ interface BaseConfig {
689
706
  * This configuration will be used by the documentation generation plugins during the `docs` command.
690
707
  */
691
708
  docs?: Record<string, any>;
709
+ /**
710
+ * Configuration for deploying the source code
711
+ *
712
+ * @remarks
713
+ * If set to `false`, the deployment will be disabled.
714
+ */
715
+ deploy?: Record<string, any> | false;
692
716
  /**
693
717
  * The path to the tsconfig file to be used by the compiler
694
718
  *
@@ -802,7 +826,7 @@ type UserConfig<TBuildConfig extends BuildConfig = BuildConfig, TBuildResolvedCo
802
826
  override?: Partial<TBuildResolvedConfig>;
803
827
  };
804
828
  };
805
- type PowerlinesCommand = "new" | "prepare" | "build" | "lint" | "test" | "docs" | "release" | "clean";
829
+ type PowerlinesCommand = "new" | "prepare" | "build" | "lint" | "test" | "docs" | "deploy" | "clean";
806
830
  /**
807
831
  * The configuration provided while executing Powerlines commands.
808
832
  */
@@ -849,14 +873,6 @@ interface MetaInfo {
849
873
  * A hash that represents the path to the project root directory
850
874
  */
851
875
  configHash: string;
852
- /**
853
- * A mapping of runtime ids to their corresponding file paths
854
- */
855
- builtinIdMap: Record<string, string>;
856
- /**
857
- * A mapping of virtual file paths to their corresponding file contents
858
- */
859
- virtualFiles: Record<string, string | null>;
860
876
  }
861
877
  interface Resolver extends Jiti {
862
878
  plugin: Jiti;
@@ -16,7 +16,7 @@ import { BabelAPI } from '@babel/helper-plugin-utils';
16
16
  import { ArrayValues } from '@stryke/types/array';
17
17
  import { TsConfigJson, CompilerOptions } from '@stryke/types/tsconfig';
18
18
  import ts from 'typescript';
19
- import { O as OutputModeType, V as VirtualFileSystemInterface, a as VirtualFile, P as PowerlinesWriteFileOptions } from './vfs-Bl84Hw2V.cjs';
19
+ import { O as OutputModeType, V as VirtualFileSystemInterface, a as VirtualFile, P as PowerlinesWriteFileOptions } from './vfs-BGmsy47f.cjs';
20
20
 
21
21
  type BabelPluginPass<TState = unknown> = PluginPass & TState;
22
22
  type BabelTransformPluginFilter = (code: string, id: string) => boolean;
@@ -45,6 +45,20 @@ interface BuildConfig {
45
45
  * @defaultValue "neutral"
46
46
  */
47
47
  platform?: "node" | "browser" | "neutral";
48
+ /**
49
+ * Array of strings indicating the polyfills to include for the build.
50
+ *
51
+ * @remarks
52
+ * This option allows you to specify which polyfills should be included in the build process to ensure compatibility with the target environment. The paths for the polyfills can use placeholder tokens (the `replacePathTokens` helper function will be used to resolve the actual values).
53
+ *
54
+ * @example
55
+ * ```ts
56
+ * {
57
+ * polyfill: ['{projectRoot}/custom-polyfill.ts']
58
+ * }
59
+ * ```
60
+ */
61
+ polyfill?: string[];
48
62
  /**
49
63
  * Array of strings indicating the order in which fields in a package.json file should be resolved to determine the entry point for a module.
50
64
  *
@@ -130,7 +144,10 @@ interface BuildConfig {
130
144
  *
131
145
  * @see https://github.com/rollup/plugins/tree/master/packages/alias
132
146
  */
133
- alias?: Record<string, string>;
147
+ alias?: Record<string, string> | Array<{
148
+ find: string | RegExp;
149
+ replacement: string;
150
+ }>;
134
151
  /**
135
152
  * A list of modules that should not be bundled, even if they are external dependencies.
136
153
  *
@@ -156,7 +173,7 @@ interface BuildConfig {
156
173
  }
157
174
  type BuildResolvedConfig = Omit<BuildConfig, "override">;
158
175
 
159
- declare const SUPPORTED_COMMANDS: readonly ["new", "clean", "prepare", "lint", "test", "build", "docs", "release", "finalize"];
176
+ declare const SUPPORTED_COMMANDS: readonly ["new", "clean", "prepare", "lint", "test", "build", "docs", "deploy", "finalize"];
160
177
  type CommandType = ArrayValues<typeof SUPPORTED_COMMANDS>;
161
178
 
162
179
  interface ResolvedEntryTypeDefinition extends TypeDefinition {
@@ -187,7 +204,7 @@ type OutputResolvedConfig = Required<Omit<OutputConfig, "assets"> & {
187
204
  /**
188
205
  * The resolved options for the Powerlines project configuration.
189
206
  */
190
- type ResolvedConfig<TUserConfig extends UserConfig = UserConfig> = Omit<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "platform" | "tsconfig" | "lint" | "test" | "build" | "transform" | "variant" | "type" | "output" | "logLevel" | "framework"> & Required<Pick<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "tsconfig" | "lint" | "test" | "build" | "transform" | "framework">> & {
207
+ type ResolvedConfig<TUserConfig extends UserConfig = UserConfig> = Omit<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "platform" | "tsconfig" | "lint" | "test" | "build" | "transform" | "deploy" | "variant" | "type" | "output" | "logLevel" | "framework"> & Required<Pick<TUserConfig, "name" | "title" | "plugins" | "mode" | "environments" | "tsconfig" | "lint" | "test" | "build" | "transform" | "deploy" | "framework">> & {
191
208
  /**
192
209
  * The configuration options that were provided inline to the Powerlines CLI.
193
210
  */
@@ -689,6 +706,13 @@ interface BaseConfig {
689
706
  * This configuration will be used by the documentation generation plugins during the `docs` command.
690
707
  */
691
708
  docs?: Record<string, any>;
709
+ /**
710
+ * Configuration for deploying the source code
711
+ *
712
+ * @remarks
713
+ * If set to `false`, the deployment will be disabled.
714
+ */
715
+ deploy?: Record<string, any> | false;
692
716
  /**
693
717
  * The path to the tsconfig file to be used by the compiler
694
718
  *
@@ -802,7 +826,7 @@ type UserConfig<TBuildConfig extends BuildConfig = BuildConfig, TBuildResolvedCo
802
826
  override?: Partial<TBuildResolvedConfig>;
803
827
  };
804
828
  };
805
- type PowerlinesCommand = "new" | "prepare" | "build" | "lint" | "test" | "docs" | "release" | "clean";
829
+ type PowerlinesCommand = "new" | "prepare" | "build" | "lint" | "test" | "docs" | "deploy" | "clean";
806
830
  /**
807
831
  * The configuration provided while executing Powerlines commands.
808
832
  */
@@ -849,14 +873,6 @@ interface MetaInfo {
849
873
  * A hash that represents the path to the project root directory
850
874
  */
851
875
  configHash: string;
852
- /**
853
- * A mapping of runtime ids to their corresponding file paths
854
- */
855
- builtinIdMap: Record<string, string>;
856
- /**
857
- * A mapping of virtual file paths to their corresponding file contents
858
- */
859
- virtualFiles: Record<string, string | null>;
860
876
  }
861
877
  interface Resolver extends Jiti {
862
878
  plugin: Jiti;
@@ -1,5 +1,5 @@
1
1
  export { EnvPluginContext, EnvPluginOptions, EnvPluginResolvedConfig, EnvPluginUserConfig, EnvType } from './plugin.cjs';
2
- export { E as EnvInterface, S as SecretsInterface } from '../runtime-DsoL32bv.cjs';
2
+ export { E as EnvInterface, S as SecretsInterface } from '../runtime-CXFOdIeH.cjs';
3
3
  import '@alloy-js/core/jsx-runtime';
4
4
  import '@deepkit/type';
5
5
  import '@stryke/capnp';
@@ -22,8 +22,6 @@ import '@babel/helper-plugin-utils';
22
22
  import '@stryke/types/array';
23
23
  import '@stryke/types/tsconfig';
24
24
  import 'typescript';
25
- import '../vfs-Bl84Hw2V.cjs';
25
+ import '../vfs-BGmsy47f.cjs';
26
26
  import '@stryke/json/types';
27
- import 'memfs';
28
27
  import 'node:fs';
29
- import 'unionfs';
@@ -1,5 +1,5 @@
1
1
  export { EnvPluginContext, EnvPluginOptions, EnvPluginResolvedConfig, EnvPluginUserConfig, EnvType } from './plugin.js';
2
- export { E as EnvInterface, S as SecretsInterface } from '../runtime-DEVUXRrw.js';
2
+ export { E as EnvInterface, S as SecretsInterface } from '../runtime-BZR8Re97.js';
3
3
  import '@alloy-js/core/jsx-runtime';
4
4
  import '@deepkit/type';
5
5
  import '@stryke/capnp';
@@ -22,8 +22,6 @@ import '@babel/helper-plugin-utils';
22
22
  import '@stryke/types/array';
23
23
  import '@stryke/types/tsconfig';
24
24
  import 'typescript';
25
- import '../vfs-Bl84Hw2V.js';
25
+ import '../vfs-BGmsy47f.js';
26
26
  import '@stryke/json/types';
27
- import 'memfs';
28
27
  import 'node:fs';
29
- import 'unionfs';
@@ -1,7 +1,7 @@
1
1
  import { Children } from '@alloy-js/core/jsx-runtime';
2
2
  import { ReflectionClass } from '@deepkit/type';
3
3
  import * as $ from '@stryke/capnp';
4
- import { B as BabelUserConfig, c as UserConfig, R as ResolvedConfig, d as BabelResolvedConfig, P as PluginContext, E as EnvInterface, S as SecretsInterface } from '../runtime-DsoL32bv.cjs';
4
+ import { B as BabelUserConfig, c as UserConfig, R as ResolvedConfig, d as BabelResolvedConfig, P as PluginContext, E as EnvInterface, S as SecretsInterface } from '../runtime-CXFOdIeH.cjs';
5
5
  import { DotenvParseOutput } from '@stryke/env/types';
6
6
  import { DotenvConfiguration, TypeDefinitionParameter, TypeDefinition } from '@stryke/types/configuration';
7
7
  import '@stryke/env/get-env-paths';
@@ -21,11 +21,9 @@ import '@babel/helper-plugin-utils';
21
21
  import '@stryke/types/array';
22
22
  import '@stryke/types/tsconfig';
23
23
  import 'typescript';
24
- import '../vfs-Bl84Hw2V.cjs';
24
+ import '../vfs-BGmsy47f.cjs';
25
25
  import '@stryke/json/types';
26
- import 'memfs';
27
26
  import 'node:fs';
28
- import 'unionfs';
29
27
 
30
28
  declare const ReflectionKind: {
31
29
  readonly NEVER: 0;
@@ -1,7 +1,7 @@
1
1
  import { Children } from '@alloy-js/core/jsx-runtime';
2
2
  import { ReflectionClass } from '@deepkit/type';
3
3
  import * as $ from '@stryke/capnp';
4
- import { B as BabelUserConfig, c as UserConfig, R as ResolvedConfig, d as BabelResolvedConfig, P as PluginContext, E as EnvInterface, S as SecretsInterface } from '../runtime-DEVUXRrw.js';
4
+ import { B as BabelUserConfig, c as UserConfig, R as ResolvedConfig, d as BabelResolvedConfig, P as PluginContext, E as EnvInterface, S as SecretsInterface } from '../runtime-BZR8Re97.js';
5
5
  import { DotenvParseOutput } from '@stryke/env/types';
6
6
  import { DotenvConfiguration, TypeDefinitionParameter, TypeDefinition } from '@stryke/types/configuration';
7
7
  import '@stryke/env/get-env-paths';
@@ -21,11 +21,9 @@ import '@babel/helper-plugin-utils';
21
21
  import '@stryke/types/array';
22
22
  import '@stryke/types/tsconfig';
23
23
  import 'typescript';
24
- import '../vfs-Bl84Hw2V.js';
24
+ import '../vfs-BGmsy47f.js';
25
25
  import '@stryke/json/types';
26
- import 'memfs';
27
26
  import 'node:fs';
28
- import 'unionfs';
29
27
 
30
28
  declare const ReflectionKind: {
31
29
  readonly NEVER: 0;
@@ -1,4 +1,4 @@
1
- export { E as EnvInterface, S as SecretsInterface } from '../runtime-DsoL32bv.cjs';
1
+ export { E as EnvInterface, S as SecretsInterface } from '../runtime-CXFOdIeH.cjs';
2
2
  import '@stryke/env/get-env-paths';
3
3
  import '@stryke/types/base';
4
4
  import '@stryke/types/package-json';
@@ -17,8 +17,6 @@ import '@babel/helper-plugin-utils';
17
17
  import '@stryke/types/array';
18
18
  import '@stryke/types/tsconfig';
19
19
  import 'typescript';
20
- import '../vfs-Bl84Hw2V.cjs';
20
+ import '../vfs-BGmsy47f.cjs';
21
21
  import '@stryke/json/types';
22
- import 'memfs';
23
22
  import 'node:fs';
24
- import 'unionfs';
@@ -1,4 +1,4 @@
1
- export { E as EnvInterface, S as SecretsInterface } from '../runtime-DEVUXRrw.js';
1
+ export { E as EnvInterface, S as SecretsInterface } from '../runtime-BZR8Re97.js';
2
2
  import '@stryke/env/get-env-paths';
3
3
  import '@stryke/types/base';
4
4
  import '@stryke/types/package-json';
@@ -17,8 +17,6 @@ import '@babel/helper-plugin-utils';
17
17
  import '@stryke/types/array';
18
18
  import '@stryke/types/tsconfig';
19
19
  import 'typescript';
20
- import '../vfs-Bl84Hw2V.js';
20
+ import '../vfs-BGmsy47f.js';
21
21
  import '@stryke/json/types';
22
- import 'memfs';
23
22
  import 'node:fs';
24
- import 'unionfs';
@@ -1,13 +1,8 @@
1
1
  import { PrimitiveJsonValue } from '@stryke/json/types';
2
- import { Volume } from 'memfs';
3
2
  import { PathLike, StatSyncOptions, Stats, RmDirOptions, RmOptions, Mode, MakeDirectoryOptions as MakeDirectoryOptions$1, PathOrFileDescriptor, WriteFileOptions as WriteFileOptions$1 } from 'node:fs';
4
- import { IUnionFs } from 'unionfs';
5
3
 
6
- declare const __VFS_INIT__ = "__VFS_INIT__";
7
- declare const __VFS_REVERT__ = "__VFS_REVERT__";
8
- declare const __VFS_CACHE__ = "__VFS_CACHE__";
9
- declare const __VFS_VIRTUAL__ = "__VFS_VIRTUAL__";
10
- declare const __VFS_UNIFIED__ = "__VFS_UNIFIED__";
4
+ declare const __VFS_PATCH__: unique symbol;
5
+ declare const __VFS_REVERT__: unique symbol;
11
6
  type OutputModeType = "fs" | "virtual";
12
7
  interface VirtualFile {
13
8
  /**
@@ -47,7 +42,24 @@ interface VirtualFile {
47
42
  */
48
43
  code: string | NodeJS.ArrayBufferView;
49
44
  }
50
- type VirtualFileSystemMetadata = Pick<VirtualFile, "id" | "details" | "variant" | "mode">;
45
+ interface VirtualFileMetadata {
46
+ /**
47
+ * The identifier for the file data.
48
+ */
49
+ id: string;
50
+ /**
51
+ * The variant of the file.
52
+ */
53
+ variant: string;
54
+ /**
55
+ * The output mode of the file.
56
+ */
57
+ mode: string;
58
+ /**
59
+ * Additional metadata associated with the file.
60
+ */
61
+ properties: Record<string, string>;
62
+ }
51
63
  interface ResolveFSOptions {
52
64
  mode?: OutputModeType;
53
65
  }
@@ -76,12 +88,18 @@ interface ResolvePathOptions extends ResolveFSOptions {
76
88
  type?: "file" | "directory";
77
89
  }
78
90
  interface VirtualFileSystemInterface {
79
- [__VFS_INIT__]: () => void;
91
+ /**
92
+ * Patches the File System to include the virtual file system (VFS) contents.
93
+ */
94
+ [__VFS_PATCH__]: () => void;
95
+ /**
96
+ * Reverts the virtual file system (VFS) to its previous state.
97
+ */
80
98
  [__VFS_REVERT__]: () => void;
81
99
  /**
82
100
  * The underlying file metadata.
83
101
  */
84
- meta: Record<string, VirtualFileSystemMetadata | undefined>;
102
+ metadata: Record<string, VirtualFileMetadata | undefined>;
85
103
  /**
86
104
  * A map of module ids to their file paths.
87
105
  */
@@ -101,7 +119,7 @@ interface VirtualFileSystemInterface {
101
119
  * @param options - Optional parameters for resolving the path.
102
120
  * @returns Whether the path or id corresponds to a file written to the file system **(actually exists on disk)**.
103
121
  */
104
- isFs: (pathOrId: string, options?: ResolvePathOptions) => boolean;
122
+ isPhysical: (pathOrId: string, options?: ResolvePathOptions) => boolean;
105
123
  /**
106
124
  * Checks if a file exists in the virtual file system (VFS).
107
125
  *
@@ -116,15 +134,6 @@ interface VirtualFileSystemInterface {
116
134
  * @returns `true` if the directory exists, otherwise `false`.
117
135
  */
118
136
  isDirectory: (path: string) => boolean;
119
- /**
120
- * Check if a path exists within one of the directories specified in the tsconfig.json's `path` field.
121
- *
122
- * @see https://www.typescriptlang.org/tsconfig#paths
123
- *
124
- * @param pathOrId - The path or id to check.
125
- * @returns Whether the path or id corresponds to a virtual file.
126
- */
127
- isTsconfigPath: (pathOrId: string) => boolean;
128
137
  /**
129
138
  * Checks if a file exists in the virtual file system (VFS).
130
139
  *
@@ -138,7 +147,7 @@ interface VirtualFileSystemInterface {
138
147
  * @param pathOrId - The path or id of the file.
139
148
  * @returns The metadata of the file if it exists, otherwise undefined.
140
149
  */
141
- getMetadata: (pathOrId: PathLike) => VirtualFileSystemMetadata | undefined;
150
+ getMetadata: (pathOrId: PathLike) => VirtualFileMetadata | undefined;
142
151
  /**
143
152
  * Gets the stats of a file in the virtual file system (VFS).
144
153
  *
@@ -346,23 +355,12 @@ interface VirtualFileSystemInterface {
346
355
  */
347
356
  resolve: (pathOrId: string, options?: ResolvePathOptions) => string | false;
348
357
  /**
349
- * Resolves a path based on TypeScript's `tsconfig.json` paths.
358
+ * Formats a path to match the virtual file system (VFS) structure.
350
359
  *
351
- * @see https://www.typescriptlang.org/tsconfig#paths
352
- *
353
- * @param path - The path to check.
354
- * @returns The resolved file path if it exists, otherwise undefined.
360
+ * @param path - The path to format.
361
+ * @returns The formatted path.
355
362
  */
356
- resolveTsconfigPath: (path: string) => string | false;
357
- /**
358
- * Resolves a package name based on TypeScript's `tsconfig.json` paths.
359
- *
360
- * @see https://www.typescriptlang.org/tsconfig#paths
361
- *
362
- * @param path - The path to check.
363
- * @returns The resolved package name if it exists, otherwise undefined.
364
- */
365
- resolveTsconfigPathPackage: (path: string) => string | false;
363
+ formatPath: (path: string) => string;
366
364
  /**
367
365
  * Resolves a path or id to a file path in the virtual file system.
368
366
  *
@@ -371,23 +369,9 @@ interface VirtualFileSystemInterface {
371
369
  */
372
370
  realpathSync: (pathOrId: string) => string;
373
371
  /**
374
- * Retrieves a partial metadata mapping of all files in the virtual file system (VFS).
375
- *
376
- * @returns A record mapping file paths to their partial metadata.
377
- */
378
- getPartialMeta: () => Record<string, Partial<VirtualFileSystemMetadata>>;
379
- /**
380
- * A map of cached file paths to their underlying file content.
381
- */
382
- [__VFS_CACHE__]: Map<string, string>;
383
- /**
384
- * A reference to the underlying virtual file system.
385
- */
386
- [__VFS_VIRTUAL__]: Volume;
387
- /**
388
- * A reference to the underlying unified file system.
372
+ * Disposes of the virtual file system (VFS), writes any virtual file changes to disk, and releases any associated resources.
389
373
  */
390
- [__VFS_UNIFIED__]: IUnionFs;
374
+ dispose: () => Promise<void>;
391
375
  }
392
376
 
393
377
  export type { OutputModeType as O, PowerlinesWriteFileOptions as P, VirtualFileSystemInterface as V, VirtualFile as a };
@@ -1,13 +1,8 @@
1
1
  import { PrimitiveJsonValue } from '@stryke/json/types';
2
- import { Volume } from 'memfs';
3
2
  import { PathLike, StatSyncOptions, Stats, RmDirOptions, RmOptions, Mode, MakeDirectoryOptions as MakeDirectoryOptions$1, PathOrFileDescriptor, WriteFileOptions as WriteFileOptions$1 } from 'node:fs';
4
- import { IUnionFs } from 'unionfs';
5
3
 
6
- declare const __VFS_INIT__ = "__VFS_INIT__";
7
- declare const __VFS_REVERT__ = "__VFS_REVERT__";
8
- declare const __VFS_CACHE__ = "__VFS_CACHE__";
9
- declare const __VFS_VIRTUAL__ = "__VFS_VIRTUAL__";
10
- declare const __VFS_UNIFIED__ = "__VFS_UNIFIED__";
4
+ declare const __VFS_PATCH__: unique symbol;
5
+ declare const __VFS_REVERT__: unique symbol;
11
6
  type OutputModeType = "fs" | "virtual";
12
7
  interface VirtualFile {
13
8
  /**
@@ -47,7 +42,24 @@ interface VirtualFile {
47
42
  */
48
43
  code: string | NodeJS.ArrayBufferView;
49
44
  }
50
- type VirtualFileSystemMetadata = Pick<VirtualFile, "id" | "details" | "variant" | "mode">;
45
+ interface VirtualFileMetadata {
46
+ /**
47
+ * The identifier for the file data.
48
+ */
49
+ id: string;
50
+ /**
51
+ * The variant of the file.
52
+ */
53
+ variant: string;
54
+ /**
55
+ * The output mode of the file.
56
+ */
57
+ mode: string;
58
+ /**
59
+ * Additional metadata associated with the file.
60
+ */
61
+ properties: Record<string, string>;
62
+ }
51
63
  interface ResolveFSOptions {
52
64
  mode?: OutputModeType;
53
65
  }
@@ -76,12 +88,18 @@ interface ResolvePathOptions extends ResolveFSOptions {
76
88
  type?: "file" | "directory";
77
89
  }
78
90
  interface VirtualFileSystemInterface {
79
- [__VFS_INIT__]: () => void;
91
+ /**
92
+ * Patches the File System to include the virtual file system (VFS) contents.
93
+ */
94
+ [__VFS_PATCH__]: () => void;
95
+ /**
96
+ * Reverts the virtual file system (VFS) to its previous state.
97
+ */
80
98
  [__VFS_REVERT__]: () => void;
81
99
  /**
82
100
  * The underlying file metadata.
83
101
  */
84
- meta: Record<string, VirtualFileSystemMetadata | undefined>;
102
+ metadata: Record<string, VirtualFileMetadata | undefined>;
85
103
  /**
86
104
  * A map of module ids to their file paths.
87
105
  */
@@ -101,7 +119,7 @@ interface VirtualFileSystemInterface {
101
119
  * @param options - Optional parameters for resolving the path.
102
120
  * @returns Whether the path or id corresponds to a file written to the file system **(actually exists on disk)**.
103
121
  */
104
- isFs: (pathOrId: string, options?: ResolvePathOptions) => boolean;
122
+ isPhysical: (pathOrId: string, options?: ResolvePathOptions) => boolean;
105
123
  /**
106
124
  * Checks if a file exists in the virtual file system (VFS).
107
125
  *
@@ -116,15 +134,6 @@ interface VirtualFileSystemInterface {
116
134
  * @returns `true` if the directory exists, otherwise `false`.
117
135
  */
118
136
  isDirectory: (path: string) => boolean;
119
- /**
120
- * Check if a path exists within one of the directories specified in the tsconfig.json's `path` field.
121
- *
122
- * @see https://www.typescriptlang.org/tsconfig#paths
123
- *
124
- * @param pathOrId - The path or id to check.
125
- * @returns Whether the path or id corresponds to a virtual file.
126
- */
127
- isTsconfigPath: (pathOrId: string) => boolean;
128
137
  /**
129
138
  * Checks if a file exists in the virtual file system (VFS).
130
139
  *
@@ -138,7 +147,7 @@ interface VirtualFileSystemInterface {
138
147
  * @param pathOrId - The path or id of the file.
139
148
  * @returns The metadata of the file if it exists, otherwise undefined.
140
149
  */
141
- getMetadata: (pathOrId: PathLike) => VirtualFileSystemMetadata | undefined;
150
+ getMetadata: (pathOrId: PathLike) => VirtualFileMetadata | undefined;
142
151
  /**
143
152
  * Gets the stats of a file in the virtual file system (VFS).
144
153
  *
@@ -346,23 +355,12 @@ interface VirtualFileSystemInterface {
346
355
  */
347
356
  resolve: (pathOrId: string, options?: ResolvePathOptions) => string | false;
348
357
  /**
349
- * Resolves a path based on TypeScript's `tsconfig.json` paths.
358
+ * Formats a path to match the virtual file system (VFS) structure.
350
359
  *
351
- * @see https://www.typescriptlang.org/tsconfig#paths
352
- *
353
- * @param path - The path to check.
354
- * @returns The resolved file path if it exists, otherwise undefined.
360
+ * @param path - The path to format.
361
+ * @returns The formatted path.
355
362
  */
356
- resolveTsconfigPath: (path: string) => string | false;
357
- /**
358
- * Resolves a package name based on TypeScript's `tsconfig.json` paths.
359
- *
360
- * @see https://www.typescriptlang.org/tsconfig#paths
361
- *
362
- * @param path - The path to check.
363
- * @returns The resolved package name if it exists, otherwise undefined.
364
- */
365
- resolveTsconfigPathPackage: (path: string) => string | false;
363
+ formatPath: (path: string) => string;
366
364
  /**
367
365
  * Resolves a path or id to a file path in the virtual file system.
368
366
  *
@@ -371,23 +369,9 @@ interface VirtualFileSystemInterface {
371
369
  */
372
370
  realpathSync: (pathOrId: string) => string;
373
371
  /**
374
- * Retrieves a partial metadata mapping of all files in the virtual file system (VFS).
375
- *
376
- * @returns A record mapping file paths to their partial metadata.
377
- */
378
- getPartialMeta: () => Record<string, Partial<VirtualFileSystemMetadata>>;
379
- /**
380
- * A map of cached file paths to their underlying file content.
381
- */
382
- [__VFS_CACHE__]: Map<string, string>;
383
- /**
384
- * A reference to the underlying virtual file system.
385
- */
386
- [__VFS_VIRTUAL__]: Volume;
387
- /**
388
- * A reference to the underlying unified file system.
372
+ * Disposes of the virtual file system (VFS), writes any virtual file changes to disk, and releases any associated resources.
389
373
  */
390
- [__VFS_UNIFIED__]: IUnionFs;
374
+ dispose: () => Promise<void>;
391
375
  }
392
376
 
393
377
  export type { OutputModeType as O, PowerlinesWriteFileOptions as P, VirtualFileSystemInterface as V, VirtualFile as a };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@powerlines/plugin-env",
3
- "version": "0.13.16",
3
+ "version": "0.13.18",
4
4
  "type": "module",
5
5
  "description": "A package containing a Powerlines plugin for injecting static .env configuration values to the code so that they're accessible at runtime.",
6
6
  "repository": {
@@ -179,9 +179,9 @@
179
179
  "@alloy-js/typescript": "^0.20.0",
180
180
  "@babel/core": "^7.28.5",
181
181
  "@babel/types": "^7.28.5",
182
- "@powerlines/alloy": "^0.11.19",
183
- "@powerlines/plugin-babel": "^0.12.19",
184
- "@powerlines/plugin-plugin": "^0.11.18",
182
+ "@powerlines/alloy": "^0.11.21",
183
+ "@powerlines/plugin-babel": "^0.12.21",
184
+ "@powerlines/plugin-plugin": "^0.11.20",
185
185
  "@storm-software/config-tools": "^1.188.40",
186
186
  "@stryke/capnp": "^0.12.21",
187
187
  "@stryke/env": "^0.20.14",
@@ -190,12 +190,12 @@
190
190
  "@stryke/string-format": "^0.12.2",
191
191
  "@stryke/type-checks": "^0.3.12",
192
192
  "@stryke/types": "^0.10.2",
193
- "powerlines": "^0.20.0"
193
+ "powerlines": "^0.22.0"
194
194
  },
195
195
  "devDependencies": {
196
196
  "@alloy-js/babel-preset": "^0.2.1",
197
197
  "@babel/preset-typescript": "^7.28.5",
198
- "@powerlines/nx": "^0.10.10",
198
+ "@powerlines/nx": "^0.10.12",
199
199
  "@storm-software/tsup": "^0.2.38",
200
200
  "@types/node": "^22.19.1",
201
201
  "tsup": "8.4.0",
@@ -203,5 +203,5 @@
203
203
  "vite": "^7.2.2"
204
204
  },
205
205
  "publishConfig": { "access": "public" },
206
- "gitHead": "e33924ab31dbf508b8983523edbaecffeebbee4f"
206
+ "gitHead": "30a4cf4f1c707fe159b55f65f1e87b14d679614d"
207
207
  }