@powerlines/plugin-babel 0.12.46 → 0.12.47

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.
@@ -16,7 +16,6 @@ import { SourceMap } from 'magic-string';
16
16
  import { Range } from 'semver';
17
17
  import { Project } from 'ts-morph';
18
18
  import { ResolveOptions as ResolveOptions$1 } from '@stryke/fs/resolve';
19
- import { StatSyncOptions, Stats, RmDirOptions, RmOptions, Mode, MakeDirectoryOptions as MakeDirectoryOptions$1, WriteFileOptions as WriteFileOptions$1 } from 'node:fs';
20
19
  import { TsConfigJson, CompilerOptions } from '@stryke/types/tsconfig';
21
20
  import ts from 'typescript';
22
21
 
@@ -206,9 +205,107 @@ interface ImportSpecifier {
206
205
  imported: string;
207
206
  }
208
207
 
209
- declare const __VFS_PATCH__ = "__VFS_PATCH__";
210
- declare const __VFS_REVERT__ = "__VFS_REVERT__";
211
- type OutputModeType = "fs" | "virtual";
208
+ declare enum StoragePreset {
209
+ VIRTUAL = "virtual",
210
+ FS = "fs"
211
+ }
212
+ /**
213
+ * Interface defining the methods and properties for a storage adapter.
214
+ */
215
+ interface StorageAdapter {
216
+ /**
217
+ * A name identifying the storage adapter type.
218
+ */
219
+ name: string;
220
+ /**
221
+ * Checks if a key exists in the storage.
222
+ *
223
+ * @param key - The key to check for existence.
224
+ * @returns A promise that resolves to `true` if the key exists, otherwise `false`.
225
+ */
226
+ exists: (key: string) => Promise<boolean>;
227
+ /**
228
+ * Synchronously checks if a key exists in the storage.
229
+ *
230
+ * @param key - The key to check for existence.
231
+ * @returns Returns `true` if the key exists, otherwise `false`.
232
+ */
233
+ existsSync: (key: string) => boolean;
234
+ /**
235
+ * Read a value associated with a key from the storage.
236
+ *
237
+ * @param key - The key to read the value for.
238
+ * @returns A promise that resolves to the value if found, otherwise `null`.
239
+ */
240
+ get: (key: string) => Promise<string | null>;
241
+ /**
242
+ * Synchronously reads the value associated with a key from the storage.
243
+ *
244
+ * @param key - The key to read the value for.
245
+ * @returns The value if found, otherwise `null`.
246
+ */
247
+ getSync: (key: string) => string | null;
248
+ /**
249
+ * Writes a value to the storage for the given key.
250
+ *
251
+ * @param key - The key to associate the value with.
252
+ * @param value - The value to store.
253
+ */
254
+ set: (key: string, value: string) => Promise<void>;
255
+ /**
256
+ * Synchronously writes a value to the storage for the given key.
257
+ *
258
+ * @param key - The key to associate the value with.
259
+ * @param value - The value to store.
260
+ */
261
+ setSync: (key: string, value: string) => void;
262
+ /**
263
+ * Removes a value from the storage.
264
+ *
265
+ * @param key - The key whose value should be removed.
266
+ */
267
+ remove: (key: string) => Promise<void>;
268
+ /**
269
+ * Synchronously removes a value from the storage.
270
+ *
271
+ * @param key - The key whose value should be removed.
272
+ */
273
+ removeSync: (key: string) => void;
274
+ /**
275
+ * Remove all entries from the storage that match the provided base path.
276
+ *
277
+ * @param base - The base path or prefix to clear entries from.
278
+ */
279
+ clear: (base?: string) => Promise<void>;
280
+ /**
281
+ * Synchronously remove all entries from the storage that match the provided base path.
282
+ *
283
+ * @param base - The base path or prefix to clear entries from.
284
+ */
285
+ clearSync: (base?: string) => void;
286
+ /**
287
+ * Lists all keys under the provided base path.
288
+ *
289
+ * @param base - The base path or prefix to list keys from.
290
+ * @returns A promise resolving to the list of keys.
291
+ */
292
+ list: (base?: string) => Promise<string[]>;
293
+ /**
294
+ * Synchronously lists all keys under the provided base path.
295
+ *
296
+ * @param base - The base path or prefix to list keys from.
297
+ * @returns The list of keys.
298
+ */
299
+ listSync: (base?: string) => string[];
300
+ /**
301
+ * Releases any resources held by the storage adapter.
302
+ */
303
+ dispose: () => MaybePromise<void>;
304
+ }
305
+ /**
306
+ * A mapping of file paths to storage adapter names and their corresponding {@link StorageAdapter} instances.
307
+ */
308
+ type StoragePort = Record<string, StorageAdapter>;
212
309
  interface VirtualFileMetadata {
213
310
  /**
214
311
  * The identifier for the file data.
@@ -228,10 +325,6 @@ interface VirtualFileMetadata {
228
325
  * - `normal`: Indicates that the file is a standard file without any special role.
229
326
  */
230
327
  type: string;
231
- /**
232
- * The output mode of the file.
233
- */
234
- mode: string;
235
328
  /**
236
329
  * Additional metadata associated with the file.
237
330
  */
@@ -253,16 +346,9 @@ interface VirtualFileData {
253
346
  * This string represents the purpose/function of the file in the virtual file system. A potential list of variants includes:
254
347
  * - `builtin`: Indicates that the file is a built-in module provided by the system.
255
348
  * - `entry`: Indicates that the file is an entry point for execution.
256
- * - `chunk`: Indicates that the file is a code chunk, typically used in code-splitting scenarios.
257
- * - `prebuilt-chunk`: Indicates that the file is a prebuilt code chunk.
258
- * - `asset`: Indicates that the file is a static asset, such as an image or stylesheet.
259
349
  * - `normal`: Indicates that the file is a standard file without any special role.
260
350
  */
261
351
  type?: string;
262
- /**
263
- * The output mode of the file.
264
- */
265
- mode?: string;
266
352
  /**
267
353
  * Additional metadata associated with the file.
268
354
  */
@@ -278,21 +364,18 @@ interface VirtualFile extends Required<VirtualFileData>, VirtualFileMetadata {
278
364
  */
279
365
  timestamp: number;
280
366
  }
281
- interface ResolveFSOptions {
282
- mode?: OutputModeType;
283
- }
284
- type MakeDirectoryOptions = (Mode | MakeDirectoryOptions$1) & ResolveFSOptions;
285
- interface PowerlinesWriteFileOptions extends ResolveFSOptions {
367
+ interface WriteOptions {
286
368
  /**
287
369
  * Should the file skip formatting before being written?
288
370
  *
289
371
  * @defaultValue false
290
372
  */
291
373
  skipFormat?: boolean;
374
+ /**
375
+ * Additional metadata for the file.
376
+ */
377
+ meta?: VirtualFileMetadata;
292
378
  }
293
- type NodeWriteFileOptions = WriteFileOptions$1;
294
- type WriteFileOptions = NodeWriteFileOptions | PowerlinesWriteFileOptions;
295
- type WriteFileData = string | NodeJS.ArrayBufferView | VirtualFileData;
296
379
  interface ResolveOptions extends ResolveOptions$1 {
297
380
  /**
298
381
  * If true, the module is being resolved as an entry point.
@@ -316,14 +399,6 @@ interface ResolveOptions extends ResolveOptions$1 {
316
399
  skipNodeModulesBundle?: boolean;
317
400
  }
318
401
  interface VirtualFileSystemInterface {
319
- /**
320
- * Patches the File System to include the virtual file system (VFS) contents.
321
- */
322
- [__VFS_PATCH__]: () => void;
323
- /**
324
- * Reverts the virtual file system (VFS) to its previous state.
325
- */
326
- [__VFS_REVERT__]: () => void;
327
402
  /**
328
403
  * The underlying file metadata.
329
404
  */
@@ -336,208 +411,92 @@ interface VirtualFileSystemInterface {
336
411
  * A map of module ids to their file paths.
337
412
  */
338
413
  paths: Readonly<Record<string, string>>;
339
- /**
340
- * Check if a path or id corresponds to a virtual file **(does not actually exists on disk)**.
341
- *
342
- * @param pathOrId - The path or id to check.
343
- * @param importer - The importer path, if any.
344
- * @param options - Optional parameters for resolving the path.
345
- * @returns Whether the path or id corresponds to a virtual file **(does not actually exists on disk)**.
346
- */
347
- isVirtual: (pathOrId: string, importer?: string, options?: ResolveOptions) => boolean;
348
- /**
349
- * Check if a path or id corresponds to a file written to the file system **(actually exists on disk)**.
350
- *
351
- * @param pathOrId - The path or id to check.
352
- * @param importer - The importer path, if any.
353
- * @param options - Optional parameters for resolving the path.
354
- * @returns Whether the path or id corresponds to a file written to the file system **(actually exists on disk)**.
355
- */
356
- isPhysical: (pathOrId: string, importer?: string, options?: ResolveOptions) => boolean;
357
414
  /**
358
415
  * Checks if a file exists in the virtual file system (VFS).
359
416
  *
360
- * @param path - The path of the file to check.
417
+ * @param path - The path or id of the file.
361
418
  * @returns `true` if the file exists, otherwise `false`.
362
419
  */
363
- isFile: (path: string) => boolean;
420
+ exists: (path: string) => Promise<boolean>;
364
421
  /**
365
- * Checks if a directory exists in the virtual file system (VFS).
422
+ * Synchronously Checks if a file exists in the virtual file system (VFS).
366
423
  *
367
- * @param path - The path of the directory to check.
368
- * @returns `true` if the directory exists, otherwise `false`.
424
+ * @param path - The path or id of the file.
425
+ * @returns `true` if the file exists, otherwise `false`.
369
426
  */
370
- isDirectory: (path: string) => boolean;
427
+ existsSync: (path: string) => boolean;
371
428
  /**
372
- * Checks if a file exists in the virtual file system (VFS).
429
+ * Checks if a file is virtual in the virtual file system (VFS).
373
430
  *
374
- * @param pathOrId - The path or id of the file.
375
- * @returns `true` if the file exists, otherwise `false`.
431
+ * @param path - The path or id of the file.
432
+ * @returns `true` if the file is virtual, otherwise `false`.
376
433
  */
377
- existsSync: (pathOrId: string) => boolean;
434
+ isVirtual: (path: string) => boolean;
378
435
  /**
379
436
  * Gets the metadata of a file in the virtual file system (VFS).
380
437
  *
381
- * @param pathOrId - The path or id of the file.
438
+ * @param path - The path or id of the file.
382
439
  * @returns The metadata of the file if it exists, otherwise undefined.
383
440
  */
384
- getMetadata: (pathOrId: string) => VirtualFileMetadata | undefined;
385
- /**
386
- * Gets the stats of a file in the virtual file system (VFS).
387
- *
388
- * @param pathOrId - The path or id of the file.
389
- * @param options - Optional parameters for getting the stats.
390
- * @returns The stats of the file if it exists, otherwise undefined.
391
- */
392
- lstat: (pathOrId: string, options?: StatSyncOptions & {
393
- bigint?: false | undefined;
394
- throwIfNoEntry: false;
395
- }) => Promise<Stats>;
396
- /**
397
- * Gets the stats of a file in the virtual file system (VFS).
398
- *
399
- * @param pathOrId - The path or id of the file.
400
- * @param options - Optional parameters for getting the stats.
401
- * @returns The stats of the file if it exists, otherwise undefined.
402
- */
403
- lstatSync: (pathOrId: string, options?: StatSyncOptions & {
404
- bigint?: false | undefined;
405
- throwIfNoEntry: false;
406
- }) => Stats | undefined;
407
- /**
408
- * Gets the stats of a file in the virtual file system (VFS).
409
- *
410
- * @param pathOrId - The path or id of the file.
411
- * @returns The stats of the file if it exists, otherwise false.
412
- */
413
- stat: (pathOrId: string, options?: StatSyncOptions & {
414
- bigint?: false | undefined;
415
- throwIfNoEntry: false;
416
- }) => Promise<Stats>;
417
- /**
418
- * Gets the stats of a file in the virtual file system (VFS).
419
- *
420
- * @param pathOrId - The path or id of the file.
421
- * @returns The stats of the file if it exists, otherwise false.
422
- */
423
- statSync: (pathOrId: string, options?: StatSyncOptions & {
424
- bigint?: false | undefined;
425
- throwIfNoEntry: false;
426
- }) => Stats | undefined;
441
+ getMetadata: (path: string) => VirtualFileMetadata | undefined;
427
442
  /**
428
443
  * Lists files in a given path.
429
444
  *
430
445
  * @param path - The path to list files from.
431
- * @param options - Options for listing files, such as encoding and recursion.
432
446
  * @returns An array of file names in the specified path.
433
447
  */
434
- readdirSync: (path: string, options?: {
435
- encoding: BufferEncoding | null;
436
- withFileTypes?: false | undefined;
437
- recursive?: boolean | undefined;
438
- } | BufferEncoding) => string[];
448
+ listSync: (path: string) => string[];
439
449
  /**
440
450
  * Lists files in a given path.
441
451
  *
442
452
  * @param path - The path to list files from.
443
- * @param options - Options for listing files, such as encoding and recursion.
444
453
  * @returns An array of file names in the specified path.
445
454
  */
446
- readdir: (path: string, options?: {
447
- encoding: BufferEncoding | null;
448
- withFileTypes?: false | undefined;
449
- recursive?: boolean | undefined;
450
- } | BufferEncoding) => Promise<string[]>;
455
+ list: (path: string) => Promise<string[]>;
451
456
  /**
452
457
  * Removes a file or symbolic link in the virtual file system (VFS).
453
458
  *
454
459
  * @param path - The path to the file to remove.
455
460
  * @returns A promise that resolves when the file is removed.
456
461
  */
457
- unlinkSync: (path: string, options?: ResolveFSOptions) => void;
462
+ removeSync: (path: string) => void;
458
463
  /**
459
464
  * Asynchronously removes a file or symbolic link in the virtual file system (VFS).
460
465
  *
461
466
  * @param path - The path to the file to remove.
462
467
  * @returns A promise that resolves when the file is removed.
463
468
  */
464
- unlink: (path: string, options?: ResolveFSOptions) => Promise<void>;
465
- /**
466
- * Removes a directory in the virtual file system (VFS).
467
- *
468
- * @param path - The path to create the directory at.
469
- * @param options - Options for creating the directory.
470
- */
471
- rmdirSync: (path: string, options?: RmDirOptions & ResolveFSOptions) => any;
472
- /**
473
- * Removes a directory in the virtual file system (VFS).
474
- *
475
- * @param path - The path to create the directory at.
476
- * @param options - Options for creating the directory.
477
- * @returns A promise that resolves to the path of the created directory, or undefined if the directory could not be created.
478
- */
479
- rmdir: (path: string, options?: RmDirOptions & ResolveFSOptions) => Promise<void>;
480
- /**
481
- * Removes a file or directory in the virtual file system (VFS).
482
- *
483
- * @param path - The path to the file or directory to remove.
484
- * @param options - Options for removing the file or directory.
485
- * @returns A promise that resolves when the file or directory is removed.
486
- */
487
- rm: (path: string, options?: RmOptions & ResolveFSOptions) => Promise<void>;
488
- /**
489
- * Synchronously removes a file or directory in the virtual file system (VFS).
490
- *
491
- * @param path - The path to the file or directory to remove.
492
- * @param options - Options for removing the file or directory.
493
- */
494
- rmSync: (path: string, options?: RmOptions & ResolveFSOptions) => void;
495
- /**
496
- * Creates a directory in the virtual file system (VFS).
497
- *
498
- * @param path - The path to create the directory at.
499
- * @param options - Options for creating the directory.
500
- * @returns A promise that resolves to the path of the created directory, or undefined if the directory could not be created.
501
- */
502
- mkdirSync: (path: string, options?: MakeDirectoryOptions) => string | undefined;
503
- /**
504
- * Creates a directory in the virtual file system (VFS).
505
- *
506
- * @param path - The path to create the directory at.
507
- * @param options - Options for creating the directory.
508
- * @returns A promise that resolves to the path of the created directory, or undefined if the directory could not be created.
509
- */
510
- mkdir: (path: string, options?: MakeDirectoryOptions) => Promise<string | undefined>;
469
+ remove: (path: string) => Promise<void>;
511
470
  /**
512
471
  * Reads a file from the virtual file system (VFS).
513
472
  *
514
- * @param pathOrId - The path or id of the file.
473
+ * @param path - The path or id of the file.
515
474
  * @returns The contents of the file if it exists, otherwise undefined.
516
475
  */
517
- readFile: (pathOrId: string) => Promise<string | undefined>;
476
+ read: (path: string) => Promise<string | undefined>;
518
477
  /**
519
478
  * Reads a file from the virtual file system (VFS).
520
479
  *
521
- * @param pathOrId - The path or id of the file.
480
+ * @param path - The path or id of the file.
522
481
  */
523
- readFileSync: (pathOrId: string) => string | undefined;
482
+ readSync: (path: string) => string | undefined;
524
483
  /**
525
484
  * Writes a file to the virtual file system (VFS).
526
485
  *
527
486
  * @param path - The path to the file.
528
487
  * @param data - The contents of the file.
529
- * @param options - Optional parameters for writing the file.
488
+ * @param options - Options for writing the file.
530
489
  * @returns A promise that resolves when the file is written.
531
490
  */
532
- writeFile: (path: string, data?: WriteFileData, options?: WriteFileOptions) => Promise<void>;
491
+ write: (path: string, data: string, options?: WriteOptions) => Promise<void>;
533
492
  /**
534
493
  * Writes a file to the virtual file system (VFS).
535
494
  *
536
495
  * @param path - The path to the file.
537
496
  * @param data - The contents of the file.
538
- * @param options - Optional parameters for writing the file.
497
+ * @param options - Options for writing the file.
539
498
  */
540
- writeFileSync: (path: string, data?: WriteFileData, options?: WriteFileOptions) => void;
499
+ writeSync: (path: string, data: string, options?: WriteOptions) => void;
541
500
  /**
542
501
  * Moves a file from one path to another in the virtual file system (VFS).
543
502
  *
@@ -580,13 +539,6 @@ interface VirtualFileSystemInterface {
580
539
  * @returns An array of file paths matching the provided pattern(s)
581
540
  */
582
541
  globSync: (pattern: string | string[]) => string[];
583
- /**
584
- * Resolves a path or id to a file path in the virtual file system.
585
- *
586
- * @param pathOrId - The path or id of the file to resolve.
587
- * @returns The resolved path of the file if it exists, otherwise false.
588
- */
589
- realpathSync: (pathOrId: string) => string;
590
542
  /**
591
543
  * A helper function to resolve modules using the Jiti resolver
592
544
  *
@@ -746,13 +698,16 @@ interface OutputConfig {
746
698
  *
747
699
  * @defaultValue "\{projectRoot\}/dist"
748
700
  */
749
- distPath?: string;
701
+ buildPath?: string;
750
702
  /**
751
- * The format of the output files
703
+ * The folder where the generated runtime artifacts will be located
752
704
  *
753
- * @defaultValue "virtual"
705
+ * @remarks
706
+ * This folder will contain all runtime artifacts and builtins generated during the "prepare" phase.
707
+ *
708
+ * @defaultValue "\{projectRoot\}/.powerlines"
754
709
  */
755
- mode?: OutputModeType;
710
+ artifactsPath?: string;
756
711
  /**
757
712
  * The path of the generated runtime declaration file relative to the workspace root.
758
713
  *
@@ -768,15 +723,6 @@ interface OutputConfig {
768
723
  * @defaultValue "powerlines"
769
724
  */
770
725
  builtinPrefix?: string;
771
- /**
772
- * The folder where the generated runtime artifacts will be located
773
- *
774
- * @remarks
775
- * This folder will contain all runtime artifacts and builtins generated during the "prepare" phase.
776
- *
777
- * @defaultValue "\{projectRoot\}/.powerlines"
778
- */
779
- artifactsFolder?: string;
780
726
  /**
781
727
  * The module format of the output files
782
728
  *
@@ -793,42 +739,21 @@ interface OutputConfig {
793
739
  * The assets can be specified as a string (path to the asset) or as an object with a `glob` property (to match multiple files). The paths are relative to the project root directory.
794
740
  */
795
741
  assets?: Array<string | AssetGlob>;
796
- }
797
- interface BaseConfig {
798
- /**
799
- * The name of the project
800
- */
801
- name?: string;
802
- /**
803
- * The project display title
804
- *
805
- * @remarks
806
- * This option is used in documentation generation and other places where a human-readable title is needed.
807
- */
808
- title?: string;
809
742
  /**
810
- * A description of the project
743
+ * A string preset or a custom {@link StoragePort} to provide fine-grained control over generated/output file storage.
811
744
  *
812
745
  * @remarks
813
- * If this option is not provided, the build process will try to use the \`description\` value from the `\package.json\` file.
814
- */
815
- description?: string;
816
- /**
817
- * The log level to use for the Powerlines processes.
746
+ * If a string preset is provided, it must be one of the following values:
747
+ * - `"virtual"`: Uses the local file system for storage.
748
+ * - `"fs"`: Uses an in-memory virtual file system for storage.
818
749
  *
819
- * @defaultValue "info"
820
- */
821
- logLevel?: LogLevelLabel | null;
822
- /**
823
- * A custom logger function to use for logging messages
824
- */
825
- customLogger?: LogFn;
826
- /**
827
- * Explicitly set a mode to run in. This mode will be used at various points throughout the Powerlines processes, such as when compiling the source code.
750
+ * If a custom {@link StoragePort} is provided, it will be used for all file storage operations during the build process.
828
751
  *
829
- * @defaultValue "production"
752
+ * @defaultValue "virtual"
830
753
  */
831
- mode?: "development" | "test" | "production";
754
+ storage?: StoragePort | StoragePreset;
755
+ }
756
+ interface BaseConfig {
832
757
  /**
833
758
  * The entry point(s) for the application
834
759
  */
@@ -912,6 +837,40 @@ interface EnvironmentConfig extends BaseConfig {
912
837
  consumer?: "client" | "server";
913
838
  }
914
839
  interface CommonUserConfig extends BaseConfig {
840
+ /**
841
+ * The name of the project
842
+ */
843
+ name?: string;
844
+ /**
845
+ * The project display title
846
+ *
847
+ * @remarks
848
+ * This option is used in documentation generation and other places where a human-readable title is needed.
849
+ */
850
+ title?: string;
851
+ /**
852
+ * A description of the project
853
+ *
854
+ * @remarks
855
+ * If this option is not provided, the build process will try to use the \`description\` value from the `\package.json\` file.
856
+ */
857
+ description?: string;
858
+ /**
859
+ * The log level to use for the Powerlines processes.
860
+ *
861
+ * @defaultValue "info"
862
+ */
863
+ logLevel?: LogLevelLabel | null;
864
+ /**
865
+ * A custom logger function to use for logging messages
866
+ */
867
+ customLogger?: LogFn;
868
+ /**
869
+ * Explicitly set a mode to run in. This mode will be used at various points throughout the Powerlines processes, such as when compiling the source code.
870
+ *
871
+ * @defaultValue "production"
872
+ */
873
+ mode?: "development" | "test" | "production";
915
874
  /**
916
875
  * The type of project being built
917
876
  *
@@ -962,7 +921,7 @@ interface CommonUserConfig extends BaseConfig {
962
921
  * A string identifier that allows a child framework or tool to identify itself when using Powerlines.
963
922
  *
964
923
  * @remarks
965
- * If no values are provided for {@link OutputConfig.dts | output.dts}, {@link OutputConfig.builtinPrefix | output.builtinPrefix}, or {@link OutputConfig.artifactsFolder | output.artifactsFolder}, this value will be used as the default.
924
+ * If no values are provided for {@link OutputConfig.dts | output.dts}, {@link OutputConfig.builtinPrefix | output.builtinPrefix}, or {@link OutputConfig.artifactsPath | output.artifactsFolder}, this value will be used as the default.
966
925
  *
967
926
  * @defaultValue "powerlines"
968
927
  */
@@ -1011,7 +970,7 @@ interface ResolvedEntryTypeDefinition extends TypeDefinition {
1011
970
  output?: string;
1012
971
  }
1013
972
  type BabelResolvedConfig = Omit<BabelUserConfig, "plugins" | "presets"> & Required<Pick<BabelUserConfig, "plugins" | "presets">>;
1014
- type EnvironmentResolvedConfig = Omit<EnvironmentConfig, "consumer" | "mode" | "ssr" | "preview"> & Required<Pick<EnvironmentConfig, "consumer" | "mode" | "ssr">> & {
973
+ type EnvironmentResolvedConfig = Omit<EnvironmentConfig, "consumer" | "ssr" | "preview"> & Required<Pick<EnvironmentConfig, "consumer" | "ssr">> & {
1015
974
  /**
1016
975
  * The name of the environment
1017
976
  */
@@ -1022,9 +981,9 @@ type EnvironmentResolvedConfig = Omit<EnvironmentConfig, "consumer" | "mode" | "
1022
981
  preview?: ResolvedPreviewOptions;
1023
982
  };
1024
983
  type ResolvedAssetGlob = AssetGlob & Required<Pick<AssetGlob, "input">>;
1025
- type OutputResolvedConfig = Required<Omit<OutputConfig, "assets"> & {
984
+ type OutputResolvedConfig = Required<Omit<OutputConfig, "assets" | "storage"> & {
1026
985
  assets: ResolvedAssetGlob[];
1027
- }>;
986
+ }> & Pick<OutputConfig, "storage">;
1028
987
  /**
1029
988
  * The resolved options for the Powerlines project configuration.
1030
989
  */
@@ -1292,17 +1251,15 @@ interface UnresolvedContext<TResolvedConfig extends ResolvedConfig = ResolvedCon
1292
1251
  * @param code - The source code of the builtin file
1293
1252
  * @param id - The unique identifier of the builtin file
1294
1253
  * @param path - An optional path to write the builtin file to
1295
- * @param options - Options for writing the file
1296
1254
  */
1297
- emitBuiltin: (code: string, id: string, path?: string, options?: PowerlinesWriteFileOptions) => Promise<void>;
1255
+ emitBuiltin: (code: string, id: string, path?: string) => Promise<void>;
1298
1256
  /**
1299
1257
  * Resolves a entry virtual file and writes it to the VFS if it does not already exist
1300
1258
  *
1301
1259
  * @param code - The source code of the entry file
1302
1260
  * @param path - An optional path to write the entry file to
1303
- * @param options - Options for writing the file
1304
1261
  */
1305
- emitEntry: (code: string, path: string, options?: PowerlinesWriteFileOptions) => Promise<void>;
1262
+ emitEntry: (code: string, path: string) => Promise<void>;
1306
1263
  /**
1307
1264
  * A function to update the context fields using a new user configuration options
1308
1265
  */