@powerlines/core 0.15.0 → 0.15.2
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/dist/constants/api.cjs +6 -5
- package/dist/constants/api.d.cts +3 -3
- package/dist/constants/api.d.cts.map +1 -1
- package/dist/constants/api.d.mts +3 -3
- package/dist/constants/api.d.mts.map +1 -1
- package/dist/constants/api.mjs +4 -4
- package/dist/constants/api.mjs.map +1 -1
- package/dist/constants/commands.cjs +3 -2
- package/dist/constants/commands.d.cts +1 -1
- package/dist/constants/commands.d.mts +1 -1
- package/dist/constants/commands.mjs +2 -2
- package/dist/constants/commands.mjs.map +1 -1
- package/dist/constants/devtools.cjs +23 -0
- package/dist/constants/devtools.d.cts +13 -0
- package/dist/constants/devtools.d.cts.map +1 -0
- package/dist/constants/devtools.d.mts +13 -0
- package/dist/constants/devtools.d.mts.map +1 -0
- package/dist/constants/devtools.mjs +14 -0
- package/dist/constants/devtools.mjs.map +1 -0
- package/dist/constants/environments.cjs +1 -0
- package/dist/constants/extensions.cjs +21 -0
- package/dist/constants/extensions.d.cts +5 -0
- package/dist/constants/extensions.d.cts.map +1 -0
- package/dist/constants/extensions.d.mts +5 -0
- package/dist/constants/extensions.d.mts.map +1 -0
- package/dist/constants/extensions.mjs +20 -0
- package/dist/constants/extensions.mjs.map +1 -0
- package/dist/constants/fs.cjs +1 -0
- package/dist/constants/hooks.cjs +1 -0
- package/dist/constants/index.cjs +48 -30
- package/dist/constants/index.d.cts +5 -3
- package/dist/constants/index.d.mts +5 -3
- package/dist/constants/index.mjs +5 -3
- package/dist/constants/log-level.cjs +90 -0
- package/dist/constants/log-level.d.cts +63 -0
- package/dist/constants/log-level.d.cts.map +1 -0
- package/dist/constants/log-level.d.mts +63 -0
- package/dist/constants/log-level.d.mts.map +1 -0
- package/dist/constants/log-level.mjs +82 -0
- package/dist/constants/log-level.mjs.map +1 -0
- package/dist/constants/meta.cjs +1 -0
- package/dist/constants/plugin.cjs +3 -2
- package/dist/constants/plugin.d.cts +2 -2
- package/dist/constants/plugin.d.mts +2 -2
- package/dist/context/base-context.cjs +127 -0
- package/dist/context/base-context.d.cts +81 -0
- package/dist/context/base-context.d.cts.map +1 -0
- package/dist/context/base-context.d.mts +81 -0
- package/dist/context/base-context.d.mts.map +1 -0
- package/dist/context/base-context.mjs +125 -0
- package/dist/context/base-context.mjs.map +1 -0
- package/dist/context/context.cjs +934 -0
- package/dist/context/context.d.cts +369 -0
- package/dist/context/context.d.cts.map +1 -0
- package/dist/context/context.d.mts +369 -0
- package/dist/context/context.d.mts.map +1 -0
- package/dist/context/context.mjs +932 -0
- package/dist/context/context.mjs.map +1 -0
- package/dist/context/environment-context.cjs +219 -0
- package/dist/context/environment-context.d.cts +100 -0
- package/dist/context/environment-context.d.cts.map +1 -0
- package/dist/context/environment-context.d.mts +100 -0
- package/dist/context/environment-context.d.mts.map +1 -0
- package/dist/context/environment-context.mjs +218 -0
- package/dist/context/environment-context.mjs.map +1 -0
- package/dist/context/execution-context.cjs +230 -0
- package/dist/context/execution-context.d.cts +101 -0
- package/dist/context/execution-context.d.cts.map +1 -0
- package/dist/context/execution-context.d.mts +101 -0
- package/dist/context/execution-context.d.mts.map +1 -0
- package/dist/context/execution-context.mjs +228 -0
- package/dist/context/execution-context.mjs.map +1 -0
- package/dist/context/index.cjs +12 -0
- package/dist/context/index.d.cts +6 -0
- package/dist/context/index.d.mts +6 -0
- package/dist/context/index.mjs +7 -0
- package/dist/context/plugin-context.cjs +83 -0
- package/dist/context/plugin-context.d.cts +18 -0
- package/dist/context/plugin-context.d.cts.map +1 -0
- package/dist/context/plugin-context.d.mts +18 -0
- package/dist/context/plugin-context.d.mts.map +1 -0
- package/dist/context/plugin-context.mjs +82 -0
- package/dist/context/plugin-context.mjs.map +1 -0
- package/dist/index.cjs +62 -9
- package/dist/index.d.cts +20 -9
- package/dist/index.d.mts +20 -9
- package/dist/index.mjs +17 -5
- package/dist/lib/config.cjs +160 -15
- package/dist/lib/config.d.cts +92 -6
- package/dist/lib/config.d.cts.map +1 -1
- package/dist/lib/config.d.mts +92 -6
- package/dist/lib/config.d.mts.map +1 -1
- package/dist/lib/config.mjs +154 -16
- package/dist/lib/config.mjs.map +1 -1
- package/dist/lib/context-helpers.cjs +43 -0
- package/dist/lib/context-helpers.d.cts +19 -0
- package/dist/lib/context-helpers.d.cts.map +1 -0
- package/dist/lib/context-helpers.d.mts +19 -0
- package/dist/lib/context-helpers.d.mts.map +1 -0
- package/dist/lib/context-helpers.mjs +41 -0
- package/dist/lib/context-helpers.mjs.map +1 -0
- package/dist/lib/entry.cjs +5 -5
- package/dist/lib/entry.d.cts +5 -5
- package/dist/lib/entry.d.cts.map +1 -1
- package/dist/lib/entry.d.mts +5 -5
- package/dist/lib/entry.d.mts.map +1 -1
- package/dist/lib/entry.mjs +5 -5
- package/dist/lib/entry.mjs.map +1 -1
- package/dist/lib/environment.cjs +72 -0
- package/dist/lib/environment.d.cts +12 -0
- package/dist/lib/environment.d.cts.map +1 -0
- package/dist/lib/environment.d.mts +12 -0
- package/dist/lib/environment.d.mts.map +1 -0
- package/dist/lib/environment.mjs +67 -0
- package/dist/lib/environment.mjs.map +1 -0
- package/dist/lib/events.cjs +43 -0
- package/dist/lib/events.d.cts +10 -0
- package/dist/lib/events.d.cts.map +1 -0
- package/dist/lib/events.d.mts +10 -0
- package/dist/lib/events.d.mts.map +1 -0
- package/dist/lib/events.mjs +42 -0
- package/dist/lib/events.mjs.map +1 -0
- package/dist/lib/generate-types.cjs +371 -0
- package/dist/lib/generate-types.d.cts +67 -0
- package/dist/lib/generate-types.d.cts.map +1 -0
- package/dist/lib/generate-types.d.mts +67 -0
- package/dist/lib/generate-types.d.mts.map +1 -0
- package/dist/lib/generate-types.mjs +368 -0
- package/dist/lib/generate-types.mjs.map +1 -0
- package/dist/lib/hooks.cjs +152 -0
- package/dist/lib/hooks.d.cts +28 -0
- package/dist/lib/hooks.d.cts.map +1 -0
- package/dist/lib/hooks.d.mts +28 -0
- package/dist/lib/hooks.d.mts.map +1 -0
- package/dist/lib/hooks.mjs +147 -0
- package/dist/lib/hooks.mjs.map +1 -0
- package/dist/lib/index.cjs +64 -9
- package/dist/lib/index.d.cts +15 -3
- package/dist/lib/index.d.mts +15 -3
- package/dist/lib/index.mjs +19 -5
- package/dist/lib/install-dependencies.cjs +25 -0
- package/dist/lib/install-dependencies.d.cts +12 -0
- package/dist/lib/install-dependencies.d.cts.map +1 -0
- package/dist/lib/install-dependencies.d.mts +12 -0
- package/dist/lib/install-dependencies.d.mts.map +1 -0
- package/dist/lib/install-dependencies.mjs +24 -0
- package/dist/lib/install-dependencies.mjs.map +1 -0
- package/dist/lib/meta.cjs +57 -0
- package/dist/lib/meta.d.cts +34 -0
- package/dist/lib/meta.d.cts.map +1 -0
- package/dist/lib/meta.d.mts +34 -0
- package/dist/lib/meta.d.mts.map +1 -0
- package/dist/lib/meta.mjs +54 -0
- package/dist/lib/meta.mjs.map +1 -0
- package/dist/lib/plugins.cjs +150 -0
- package/dist/lib/plugins.d.cts +40 -0
- package/dist/lib/plugins.d.cts.map +1 -0
- package/dist/lib/plugins.d.mts +40 -0
- package/dist/lib/plugins.d.mts.map +1 -0
- package/dist/lib/plugins.mjs +146 -0
- package/dist/lib/plugins.mjs.map +1 -0
- package/dist/lib/resolver.cjs +35 -0
- package/dist/lib/resolver.d.cts +21 -0
- package/dist/lib/resolver.d.cts.map +1 -0
- package/dist/lib/resolver.d.mts +21 -0
- package/dist/lib/resolver.d.mts.map +1 -0
- package/dist/lib/resolver.mjs +33 -0
- package/dist/lib/resolver.mjs.map +1 -0
- package/dist/lib/schemas.cjs +9 -0
- package/dist/lib/schemas.d.cts +2 -0
- package/dist/lib/schemas.d.mts +2 -0
- package/dist/lib/schemas.mjs +3 -0
- package/dist/lib/streaming-channel.cjs +260 -0
- package/dist/lib/streaming-channel.d.cts +133 -0
- package/dist/lib/streaming-channel.d.cts.map +1 -0
- package/dist/lib/streaming-channel.d.mts +133 -0
- package/dist/lib/streaming-channel.d.mts.map +1 -0
- package/dist/lib/streaming-channel.mjs +258 -0
- package/dist/lib/streaming-channel.mjs.map +1 -0
- package/dist/lib/typescript/index.cjs +16 -0
- package/dist/lib/typescript/index.d.cts +3 -0
- package/dist/lib/typescript/index.d.mts +3 -0
- package/dist/lib/typescript/index.mjs +4 -0
- package/dist/lib/typescript/ts-morph.cjs +105 -0
- package/dist/lib/typescript/ts-morph.d.cts +38 -0
- package/dist/lib/typescript/ts-morph.d.cts.map +1 -0
- package/dist/lib/typescript/ts-morph.d.mts +38 -0
- package/dist/lib/typescript/ts-morph.d.mts.map +1 -0
- package/dist/lib/typescript/ts-morph.mjs +102 -0
- package/dist/lib/typescript/ts-morph.mjs.map +1 -0
- package/dist/lib/typescript/tsconfig.cjs +253 -0
- package/dist/lib/typescript/tsconfig.d.cts +77 -0
- package/dist/lib/typescript/tsconfig.d.cts.map +1 -0
- package/dist/lib/typescript/tsconfig.d.mts +77 -0
- package/dist/lib/typescript/tsconfig.d.mts.map +1 -0
- package/dist/lib/typescript/tsconfig.mjs +240 -0
- package/dist/lib/typescript/tsconfig.mjs.map +1 -0
- package/dist/lib/unplugin/helpers.cjs +2 -2
- package/dist/lib/unplugin/module-resolution.cjs +18 -18
- package/dist/lib/unplugin/module-resolution.d.cts +2 -2
- package/dist/lib/unplugin/module-resolution.d.cts.map +1 -1
- package/dist/lib/unplugin/module-resolution.d.mts +2 -2
- package/dist/lib/unplugin/module-resolution.d.mts.map +1 -1
- package/dist/lib/unplugin/module-resolution.mjs +18 -18
- package/dist/lib/unplugin/module-resolution.mjs.map +1 -1
- package/dist/lib/unplugin/plugin.cjs +55 -62
- package/dist/lib/unplugin/plugin.d.cts +11 -12
- package/dist/lib/unplugin/plugin.d.cts.map +1 -1
- package/dist/lib/unplugin/plugin.d.mts +11 -12
- package/dist/lib/unplugin/plugin.d.mts.map +1 -1
- package/dist/lib/unplugin/plugin.mjs +55 -62
- package/dist/lib/unplugin/plugin.mjs.map +1 -1
- package/dist/lib/utilities/file-header.cjs +2 -2
- package/dist/lib/utilities/file-header.mjs +2 -2
- package/dist/lib/utilities/file-header.mjs.map +1 -1
- package/dist/lib/utilities/format.cjs +1 -1
- package/dist/lib/utilities/format.mjs +1 -1
- package/dist/lib/utilities/index.cjs +2 -2
- package/dist/lib/utilities/index.mjs +2 -2
- package/dist/lib/utilities/write-file.cjs +1 -2
- package/dist/lib/utilities/write-file.d.cts +1 -1
- package/dist/lib/utilities/write-file.d.cts.map +1 -1
- package/dist/lib/utilities/write-file.d.mts +1 -1
- package/dist/lib/utilities/write-file.d.mts.map +1 -1
- package/dist/lib/utilities/write-file.mjs +1 -2
- package/dist/lib/utilities/write-file.mjs.map +1 -1
- package/dist/lib/vfs.cjs +1104 -0
- package/dist/lib/vfs.d.cts +321 -0
- package/dist/lib/vfs.d.cts.map +1 -0
- package/dist/lib/vfs.d.mts +321 -0
- package/dist/lib/vfs.d.mts.map +1 -0
- package/dist/lib/vfs.mjs +1102 -0
- package/dist/lib/vfs.mjs.map +1 -0
- package/dist/plugin-base.cjs +1 -1
- package/dist/plugin-base.mjs +1 -1
- package/dist/plugin-base.mjs.map +1 -1
- package/dist/plugin-utils/build-helpers.cjs +2 -2
- package/dist/plugin-utils/build-helpers.d.cts +2 -2
- package/dist/plugin-utils/build-helpers.d.cts.map +1 -1
- package/dist/plugin-utils/build-helpers.d.mts +2 -2
- package/dist/plugin-utils/build-helpers.d.mts.map +1 -1
- package/dist/plugin-utils/build-helpers.mjs +2 -2
- package/dist/plugin-utils/build-helpers.mjs.map +1 -1
- package/dist/plugin-utils/context-helpers.cjs +22 -12
- package/dist/plugin-utils/context-helpers.d.cts +9 -1
- package/dist/plugin-utils/context-helpers.d.cts.map +1 -1
- package/dist/plugin-utils/context-helpers.d.mts +9 -1
- package/dist/plugin-utils/context-helpers.d.mts.map +1 -1
- package/dist/plugin-utils/context-helpers.mjs +22 -13
- package/dist/plugin-utils/context-helpers.mjs.map +1 -1
- package/dist/plugin-utils/filter.cjs +13 -5
- package/dist/plugin-utils/filter.d.cts +2 -1
- package/dist/plugin-utils/filter.d.cts.map +1 -1
- package/dist/plugin-utils/filter.d.mts +2 -1
- package/dist/plugin-utils/filter.d.mts.map +1 -1
- package/dist/plugin-utils/filter.mjs +13 -6
- package/dist/plugin-utils/filter.mjs.map +1 -1
- package/dist/plugin-utils/format.cjs +44 -0
- package/dist/plugin-utils/format.d.cts +11 -0
- package/dist/plugin-utils/format.d.cts.map +1 -0
- package/dist/plugin-utils/format.d.mts +11 -0
- package/dist/plugin-utils/format.d.mts.map +1 -0
- package/dist/plugin-utils/format.mjs +43 -0
- package/dist/plugin-utils/format.mjs.map +1 -0
- package/dist/plugin-utils/helpers.cjs +6 -6
- package/dist/plugin-utils/helpers.d.cts +15 -15
- package/dist/plugin-utils/helpers.d.cts.map +1 -1
- package/dist/plugin-utils/helpers.d.mts +15 -15
- package/dist/plugin-utils/helpers.d.mts.map +1 -1
- package/dist/plugin-utils/helpers.mjs +1 -1
- package/dist/plugin-utils/helpers.mjs.map +1 -1
- package/dist/plugin-utils/index.cjs +34 -4
- package/dist/plugin-utils/index.d.cts +7 -4
- package/dist/plugin-utils/index.d.mts +7 -4
- package/dist/plugin-utils/index.mjs +9 -6
- package/dist/plugin-utils/install.cjs +47 -0
- package/dist/plugin-utils/install.d.cts +23 -0
- package/dist/plugin-utils/install.d.cts.map +1 -0
- package/dist/plugin-utils/install.d.mts +23 -0
- package/dist/plugin-utils/install.d.mts.map +1 -0
- package/dist/plugin-utils/install.mjs +45 -0
- package/dist/plugin-utils/install.mjs.map +1 -0
- package/dist/plugin-utils/logging.cjs +588 -1
- package/dist/plugin-utils/logging.d.cts +93 -1
- package/dist/plugin-utils/logging.d.cts.map +1 -1
- package/dist/plugin-utils/logging.d.mts +93 -1
- package/dist/plugin-utils/logging.d.mts.map +1 -1
- package/dist/plugin-utils/logging.mjs +572 -1
- package/dist/plugin-utils/logging.mjs.map +1 -1
- package/dist/plugin-utils/merge.cjs +1 -1
- package/dist/plugin-utils/merge.mjs +1 -1
- package/dist/plugin-utils/modules.cjs +1 -1
- package/dist/plugin-utils/modules.mjs +1 -1
- package/dist/plugin-utils/modules.mjs.map +1 -1
- package/dist/plugin-utils/paths.cjs +6 -2
- package/dist/plugin-utils/paths.mjs +6 -2
- package/dist/plugin-utils/paths.mjs.map +1 -1
- package/dist/plugin-utils/virtual.cjs +80 -0
- package/dist/plugin-utils/virtual.d.cts +69 -0
- package/dist/plugin-utils/virtual.d.cts.map +1 -0
- package/dist/plugin-utils/virtual.d.mts +69 -0
- package/dist/plugin-utils/virtual.d.mts.map +1 -0
- package/dist/plugin-utils/virtual.mjs +73 -0
- package/dist/plugin-utils/virtual.mjs.map +1 -0
- package/dist/schemas/fs.cjs +232 -0
- package/dist/schemas/fs.d.cts +127 -0
- package/dist/schemas/fs.d.cts.map +1 -0
- package/dist/schemas/fs.d.mts +127 -0
- package/dist/schemas/fs.d.mts.map +1 -0
- package/dist/schemas/fs.mjs +226 -0
- package/dist/schemas/fs.mjs.map +1 -0
- package/dist/storage/base.cjs +216 -0
- package/dist/storage/base.d.cts +201 -0
- package/dist/storage/base.d.cts.map +1 -0
- package/dist/storage/base.d.mts +201 -0
- package/dist/storage/base.d.mts.map +1 -0
- package/dist/storage/base.mjs +215 -0
- package/dist/storage/base.mjs.map +1 -0
- package/dist/storage/file-system.cjs +180 -0
- package/dist/storage/file-system.d.cts +129 -0
- package/dist/storage/file-system.d.cts.map +1 -0
- package/dist/storage/file-system.d.mts +129 -0
- package/dist/storage/file-system.d.mts.map +1 -0
- package/dist/storage/file-system.mjs +179 -0
- package/dist/storage/file-system.mjs.map +1 -0
- package/dist/storage/helpers.cjs +37 -0
- package/dist/storage/helpers.d.cts +25 -0
- package/dist/storage/helpers.d.cts.map +1 -0
- package/dist/storage/helpers.d.mts +25 -0
- package/dist/storage/helpers.d.mts.map +1 -0
- package/dist/storage/helpers.mjs +34 -0
- package/dist/storage/helpers.mjs.map +1 -0
- package/dist/storage/index.cjs +12 -0
- package/dist/storage/index.d.cts +5 -0
- package/dist/storage/index.d.mts +5 -0
- package/dist/storage/index.mjs +6 -0
- package/dist/storage/virtual.cjs +98 -0
- package/dist/storage/virtual.d.cts +80 -0
- package/dist/storage/virtual.d.cts.map +1 -0
- package/dist/storage/virtual.d.mts +80 -0
- package/dist/storage/virtual.d.mts.map +1 -0
- package/dist/storage/virtual.mjs +97 -0
- package/dist/storage/virtual.mjs.map +1 -0
- package/dist/types/api.d.cts +18 -152
- package/dist/types/api.d.cts.map +1 -1
- package/dist/types/api.d.mts +18 -152
- package/dist/types/api.d.mts.map +1 -1
- package/dist/types/config.d.cts +194 -135
- package/dist/types/config.d.cts.map +1 -1
- package/dist/types/config.d.mts +195 -136
- package/dist/types/config.d.mts.map +1 -1
- package/dist/types/context.d.cts +140 -130
- package/dist/types/context.d.cts.map +1 -1
- package/dist/types/context.d.mts +143 -133
- package/dist/types/context.d.mts.map +1 -1
- package/dist/types/fs.d.mts +1 -1
- package/dist/types/index.d.cts +5 -6
- package/dist/types/index.d.mts +5 -6
- package/dist/types/logging.d.cts +161 -0
- package/dist/types/logging.d.cts.map +1 -0
- package/dist/types/logging.d.mts +161 -0
- package/dist/types/logging.d.mts.map +1 -0
- package/dist/types/plugin.d.cts +6 -9
- package/dist/types/plugin.d.cts.map +1 -1
- package/dist/types/plugin.d.mts +6 -9
- package/dist/types/plugin.d.mts.map +1 -1
- package/dist/types/tsconfig.d.mts +1 -1
- package/dist/types/unplugin.d.cts +6 -27
- package/dist/types/unplugin.d.cts.map +1 -1
- package/dist/types/unplugin.d.mts +6 -27
- package/dist/types/unplugin.d.mts.map +1 -1
- package/package.json +259 -457
- package/schemas/fs.capnp +42 -0
- package/dist/constants/virtual-modules.cjs +0 -8
- package/dist/constants/virtual-modules.d.cts +0 -6
- package/dist/constants/virtual-modules.d.cts.map +0 -1
- package/dist/constants/virtual-modules.d.mts +0 -6
- package/dist/constants/virtual-modules.d.mts.map +0 -1
- package/dist/constants/virtual-modules.mjs +0 -7
- package/dist/constants/virtual-modules.mjs.map +0 -1
- package/dist/lib/logger.cjs +0 -99
- package/dist/lib/logger.d.cts +0 -53
- package/dist/lib/logger.d.cts.map +0 -1
- package/dist/lib/logger.d.mts +0 -53
- package/dist/lib/logger.d.mts.map +0 -1
- package/dist/lib/logger.mjs +0 -93
- package/dist/lib/logger.mjs.map +0 -1
- package/dist/types/_internal.cjs +0 -0
- package/dist/types/_internal.d.cts +0 -106
- package/dist/types/_internal.d.cts.map +0 -1
- package/dist/types/_internal.d.mts +0 -106
- package/dist/types/_internal.d.mts.map +0 -1
- package/dist/types/_internal.mjs +0 -1
- package/dist/types/commands.d.cts +0 -16
- package/dist/types/commands.d.cts.map +0 -1
- package/dist/types/commands.d.mts +0 -16
- package/dist/types/commands.d.mts.map +0 -1
- package/dist/types/utils.d.cts +0 -9
- package/dist/types/utils.d.cts.map +0 -1
- package/dist/types/utils.d.mts +0 -9
- package/dist/types/utils.d.mts.map +0 -1
package/dist/types/context.d.mts
CHANGED
|
@@ -1,35 +1,36 @@
|
|
|
1
1
|
import { ResolveOptions, VirtualFile, VirtualFileSystemInterface, WriteOptions } from "./fs.mjs";
|
|
2
2
|
import { Plugin } from "./plugin.mjs";
|
|
3
|
-
import { HooksList, HooksListItem } from "./hooks.mjs";
|
|
3
|
+
import { CallHookOptions, HooksList, HooksListItem, InferHookParameters, InferHookReturnType } from "./hooks.mjs";
|
|
4
|
+
import { LogFn, LogMessage, Logger, LoggerOptions } from "./logging.mjs";
|
|
4
5
|
import { ParsedTypeScriptConfig } from "./tsconfig.mjs";
|
|
5
|
-
import { EnvironmentResolvedConfig,
|
|
6
|
-
import { ExternalIdResult, UnpluginBuildContext, UnpluginContext, UnpluginMessage } from "unplugin";
|
|
7
|
-
import MagicString, { SourceMap } from "magic-string";
|
|
8
|
-
import { Jiti } from "jiti";
|
|
6
|
+
import { EnvironmentResolvedConfig, ExecutionOptions, Options, PluginConfig, ResolvedConfig, ResolvedEntryTypeDefinition } from "./config.mjs";
|
|
9
7
|
import { EnvPaths } from "@stryke/env/get-env-paths";
|
|
8
|
+
import { Jiti } from "jiti";
|
|
9
|
+
import { ExternalIdResult, UnpluginBuildContext } from "unplugin";
|
|
10
|
+
import MagicString, { SourceMap } from "magic-string";
|
|
10
11
|
import { FetchRequestOptions } from "@stryke/http/fetch";
|
|
11
|
-
import { PackageJson } from "@stryke/types/package-json";
|
|
12
12
|
import { ParseResult, ParserOptions } from "oxc-parser";
|
|
13
|
-
import { Range } from "semver";
|
|
14
13
|
import { RequestInfo, Response } from "undici";
|
|
14
|
+
import { PackageJson } from "@stryke/types/package-json";
|
|
15
|
+
import { Range } from "semver";
|
|
15
16
|
import { Unimport } from "unimport";
|
|
16
17
|
|
|
17
18
|
//#region src/types/context.d.ts
|
|
18
|
-
|
|
19
|
+
type MetaInfo = Record<string, any> & {
|
|
19
20
|
/**
|
|
20
21
|
* The checksum generated from the resolved options
|
|
21
22
|
*/
|
|
22
23
|
checksum: string;
|
|
23
24
|
/**
|
|
24
|
-
* The
|
|
25
|
+
* The execution id
|
|
25
26
|
*/
|
|
26
|
-
|
|
27
|
+
executionId: string;
|
|
27
28
|
/**
|
|
28
29
|
* The release id
|
|
29
30
|
*/
|
|
30
31
|
releaseId: string;
|
|
31
32
|
/**
|
|
32
|
-
* The
|
|
33
|
+
* The execution timestamp
|
|
33
34
|
*/
|
|
34
35
|
timestamp: number;
|
|
35
36
|
/**
|
|
@@ -40,7 +41,7 @@ interface MetaInfo {
|
|
|
40
41
|
* A hash that represents the path to the configuration root directory
|
|
41
42
|
*/
|
|
42
43
|
configHash: string;
|
|
43
|
-
}
|
|
44
|
+
};
|
|
44
45
|
interface Resolver extends Jiti {
|
|
45
46
|
plugin: Jiti;
|
|
46
47
|
}
|
|
@@ -134,15 +135,15 @@ interface ResolveResult extends ExternalIdResult {
|
|
|
134
135
|
* @remarks
|
|
135
136
|
* This context provides the foundational structure for interacting with the Powerlines engine.
|
|
136
137
|
*/
|
|
137
|
-
interface BaseContext {
|
|
138
|
+
interface BaseContext<TSystemContext = unknown> extends Pick<Required<Options>, "cwd"> {
|
|
138
139
|
/**
|
|
139
|
-
* The
|
|
140
|
+
* The system instance associated with the context, which can be used to interact with the Powerlines engine and perform various operations during the build process. The specific type of the system may vary depending on the environment and use case, but it typically provides methods for logging, file system operations, and other interactions with the Powerlines engine.
|
|
140
141
|
*/
|
|
141
|
-
|
|
142
|
+
system: TSystemContext;
|
|
142
143
|
/**
|
|
143
144
|
* The timestamp when the context was initialized
|
|
144
145
|
*/
|
|
145
|
-
timestamp:
|
|
146
|
+
timestamp: number;
|
|
146
147
|
/**
|
|
147
148
|
* The Powerlines environment paths
|
|
148
149
|
*/
|
|
@@ -152,41 +153,37 @@ interface BaseContext {
|
|
|
152
153
|
*/
|
|
153
154
|
powerlinesPath: string;
|
|
154
155
|
/**
|
|
155
|
-
* The
|
|
156
|
-
*/
|
|
157
|
-
configFile: ParsedUserConfig;
|
|
158
|
-
/**
|
|
159
|
-
* The log level to use for the Powerlines processes.
|
|
156
|
+
* The options provided to the Powerlines process.
|
|
160
157
|
*/
|
|
161
|
-
|
|
158
|
+
options: Options;
|
|
162
159
|
/**
|
|
163
|
-
*
|
|
160
|
+
* An instance of the Powerlines logger client that can be used to generate log messages with consistent formatting and metadata.
|
|
164
161
|
*/
|
|
165
|
-
|
|
162
|
+
logger: Logger;
|
|
166
163
|
/**
|
|
167
164
|
* A logging function for fatal messages
|
|
168
165
|
*/
|
|
169
|
-
fatal: (message: string |
|
|
166
|
+
fatal: (message: string | LogMessage | Error) => void;
|
|
170
167
|
/**
|
|
171
168
|
* A logging function for error messages
|
|
172
169
|
*/
|
|
173
|
-
error: (message: string |
|
|
170
|
+
error: (message: string | LogMessage | Error) => void;
|
|
174
171
|
/**
|
|
175
172
|
* A logging function for warning messages
|
|
176
173
|
*/
|
|
177
|
-
warn: (message: string |
|
|
174
|
+
warn: (message: string | LogMessage) => void;
|
|
178
175
|
/**
|
|
179
176
|
* A logging function for informational messages
|
|
180
177
|
*/
|
|
181
|
-
info: (message: string |
|
|
178
|
+
info: (message: string | LogMessage) => void;
|
|
182
179
|
/**
|
|
183
180
|
* A logging function for debug messages
|
|
184
181
|
*/
|
|
185
|
-
debug: (message: string |
|
|
182
|
+
debug: (message: string | LogMessage) => void;
|
|
186
183
|
/**
|
|
187
184
|
* A logging function for trace messages
|
|
188
185
|
*/
|
|
189
|
-
trace: (message: string |
|
|
186
|
+
trace: (message: string | LogMessage) => void;
|
|
190
187
|
/**
|
|
191
188
|
* A function to create a timer for measuring the duration of asynchronous operations
|
|
192
189
|
*
|
|
@@ -204,36 +201,17 @@ interface BaseContext {
|
|
|
204
201
|
/**
|
|
205
202
|
* Create a new logger instance
|
|
206
203
|
*
|
|
207
|
-
* @param
|
|
208
|
-
* @returns A logger
|
|
204
|
+
* @param options - The configuration options to use for the logger instance, which can be used to customize the appearance and behavior of the log messages generated by the logger. This is typically the name of the plugin or module that is creating the logger instance.
|
|
205
|
+
* @returns A logger client instance that can be used to generate log messages with consistent formatting and metadata.
|
|
209
206
|
*/
|
|
210
|
-
|
|
207
|
+
createLogger: (options: LoggerOptions, logFn?: LogFn) => Logger;
|
|
211
208
|
/**
|
|
212
|
-
* Extend the current logger instance with a new
|
|
209
|
+
* Extend the current logger instance with a new source
|
|
213
210
|
*
|
|
214
|
-
* @param
|
|
215
|
-
* @returns A logger
|
|
211
|
+
* @param options - The overlay metadata to use for the badge in the log output.
|
|
212
|
+
* @returns A logger client instance that extends the current logger with the provided configuration options.
|
|
216
213
|
*/
|
|
217
|
-
|
|
218
|
-
/**
|
|
219
|
-
* A function to create a deep clone of the context
|
|
220
|
-
*
|
|
221
|
-
* @remarks
|
|
222
|
-
* This function is used to create a copy of the context for a specific environment, allowing for environment-specific modifications without affecting the global context.
|
|
223
|
-
*/
|
|
224
|
-
clone: () => Promise<BaseContext>;
|
|
225
|
-
}
|
|
226
|
-
/**
|
|
227
|
-
* The Powerlines engine context.
|
|
228
|
-
*
|
|
229
|
-
* @remarks
|
|
230
|
-
* This context is used during the execution of the Powerlines engine, providing access to the input user configurations.
|
|
231
|
-
*/
|
|
232
|
-
interface EngineContext extends BaseContext {
|
|
233
|
-
/**
|
|
234
|
-
* A list of API contexts for each configured run instance
|
|
235
|
-
*/
|
|
236
|
-
executions: ResolvedExecutionOptions[];
|
|
214
|
+
extendLogger: (options: LoggerOptions, logFn?: LogFn) => Logger;
|
|
237
215
|
}
|
|
238
216
|
/**
|
|
239
217
|
* The unresolved Powerlines context.
|
|
@@ -241,19 +219,17 @@ interface EngineContext extends BaseContext {
|
|
|
241
219
|
* @remarks
|
|
242
220
|
* This context is used before the user configuration has been fully resolved after the `config`.
|
|
243
221
|
*/
|
|
244
|
-
interface UnresolvedContext<TResolvedConfig extends ResolvedConfig = ResolvedConfig> extends BaseContext {
|
|
222
|
+
interface UnresolvedContext<TResolvedConfig extends ResolvedConfig = ResolvedConfig, TSystemContext = unknown> extends BaseContext<TSystemContext> {
|
|
245
223
|
/**
|
|
246
|
-
* The options provided to the Powerlines process
|
|
224
|
+
* The options provided to the Powerlines process, resolved with default values and merged with any configuration provided by plugins or other sources. This is typically the final configuration used during the build process, but may also include additional options that are relevant to the context and its interactions with the Powerlines engine.
|
|
247
225
|
*/
|
|
248
|
-
options:
|
|
226
|
+
options: ExecutionOptions;
|
|
249
227
|
/**
|
|
250
228
|
* An object containing the options provided to Powerlines
|
|
251
229
|
*/
|
|
252
|
-
config: Omit<TResolvedConfig
|
|
253
|
-
output: TResolvedConfig["output"];
|
|
254
|
-
};
|
|
230
|
+
config: Omit<TResolvedConfig, "pluginConfig">;
|
|
255
231
|
/**
|
|
256
|
-
*
|
|
232
|
+
* A place to store metadata information on the context for access in plugins and other parts of the system. This can be used to store information about the current execution, such as a unique identifier for the execution, timestamps, or any other relevant data that may be useful for plugins or other parts of the system to access during the build process.
|
|
257
233
|
*/
|
|
258
234
|
meta: MetaInfo;
|
|
259
235
|
/**
|
|
@@ -263,31 +239,49 @@ interface UnresolvedContext<TResolvedConfig extends ResolvedConfig = ResolvedCon
|
|
|
263
239
|
/**
|
|
264
240
|
* The path to a directory where the reflection data buffers (used by the build processes) are stored
|
|
265
241
|
*/
|
|
266
|
-
dataPath: string;
|
|
242
|
+
readonly dataPath: string;
|
|
267
243
|
/**
|
|
268
244
|
* The path to a directory where the project cache (used by the build processes) is stored
|
|
269
245
|
*/
|
|
270
|
-
cachePath: string;
|
|
246
|
+
readonly cachePath: string;
|
|
271
247
|
/**
|
|
272
248
|
* The Powerlines artifacts directory
|
|
273
249
|
*/
|
|
274
|
-
artifactsPath: string;
|
|
250
|
+
readonly artifactsPath: string;
|
|
275
251
|
/**
|
|
276
252
|
* The path to the Powerlines builtin runtime modules directory
|
|
277
253
|
*/
|
|
278
|
-
builtinsPath: string;
|
|
254
|
+
readonly builtinsPath: string;
|
|
279
255
|
/**
|
|
280
256
|
* The path to the Powerlines entry modules directory
|
|
281
257
|
*/
|
|
282
|
-
entryPath: string;
|
|
258
|
+
readonly entryPath: string;
|
|
283
259
|
/**
|
|
284
260
|
* The path to the Powerlines infrastructure modules directory
|
|
285
261
|
*/
|
|
286
|
-
infrastructurePath: string;
|
|
262
|
+
readonly infrastructurePath: string;
|
|
287
263
|
/**
|
|
288
264
|
* The path to the Powerlines TypeScript declaration files directory
|
|
289
265
|
*/
|
|
290
|
-
typesPath: string;
|
|
266
|
+
readonly typesPath: string;
|
|
267
|
+
/**
|
|
268
|
+
* Invokes the configured plugin hooks
|
|
269
|
+
*
|
|
270
|
+
* @remarks
|
|
271
|
+
* By default, it will call the `"pre"`, `"normal"`, and `"post"` ordered hooks in sequence
|
|
272
|
+
*
|
|
273
|
+
* @param hook - The hook to call
|
|
274
|
+
* @param options - The options to provide to the hook
|
|
275
|
+
* @param args - The arguments to pass to the hook
|
|
276
|
+
* @returns The result of the hook call
|
|
277
|
+
*/
|
|
278
|
+
callHook: <TKey extends string>(hook: TKey, options: CallHookOptions & {
|
|
279
|
+
environment?: string | EnvironmentContext<TResolvedConfig>;
|
|
280
|
+
}, ...args: InferHookParameters<PluginContext<TResolvedConfig>, TKey>) => Promise<InferHookReturnType<PluginContext<TResolvedConfig>, TKey> | undefined>;
|
|
281
|
+
/**
|
|
282
|
+
* The virtual file system interface for managing files during the build process
|
|
283
|
+
*/
|
|
284
|
+
fs: VirtualFileSystemInterface;
|
|
291
285
|
/**
|
|
292
286
|
* The project's `package.json` file content
|
|
293
287
|
*/
|
|
@@ -312,10 +306,6 @@ interface UnresolvedContext<TResolvedConfig extends ResolvedConfig = ResolvedCon
|
|
|
312
306
|
* The entry points of the source code
|
|
313
307
|
*/
|
|
314
308
|
entry: ResolvedEntryTypeDefinition[];
|
|
315
|
-
/**
|
|
316
|
-
* The virtual file system manager used during the build process to reference generated runtime files
|
|
317
|
-
*/
|
|
318
|
-
fs: VirtualFileSystemInterface;
|
|
319
309
|
/**
|
|
320
310
|
* The Jiti module resolver
|
|
321
311
|
*/
|
|
@@ -490,39 +480,42 @@ interface UnresolvedContext<TResolvedConfig extends ResolvedConfig = ResolvedCon
|
|
|
490
480
|
* @remarks
|
|
491
481
|
* This context is used after the user configuration has been fully resolved and merged with default values, providing access to the final configuration options and utility functions for interacting with the Powerlines engine.
|
|
492
482
|
*/
|
|
493
|
-
type Context<TResolvedConfig extends ResolvedConfig = ResolvedConfig> = Omit<UnresolvedContext<TResolvedConfig>, "config"> & {
|
|
483
|
+
type Context<TResolvedConfig extends ResolvedConfig = ResolvedConfig, TSystemContext = unknown> = Omit<UnresolvedContext<TResolvedConfig, TSystemContext>, "config" | "callHook"> & {
|
|
494
484
|
/**
|
|
495
485
|
* The fully resolved Powerlines configuration
|
|
496
486
|
*/
|
|
497
487
|
config: TResolvedConfig;
|
|
498
488
|
/**
|
|
499
|
-
*
|
|
500
|
-
*/
|
|
501
|
-
setup: () => Promise<void>;
|
|
502
|
-
/**
|
|
503
|
-
* A function to create a deep clone of the context
|
|
489
|
+
* Invokes the configured plugin hooks
|
|
504
490
|
*
|
|
505
491
|
* @remarks
|
|
506
|
-
*
|
|
492
|
+
* By default, it will call the `"pre"`, `"normal"`, and `"post"` ordered hooks in sequence
|
|
493
|
+
*
|
|
494
|
+
* @param hook - The hook to call
|
|
495
|
+
* @param options - The options to provide to the hook
|
|
496
|
+
* @param args - The arguments to pass to the hook
|
|
497
|
+
* @returns The result of the hook call
|
|
507
498
|
*/
|
|
508
|
-
|
|
499
|
+
callHook: <TKey extends string>(hook: TKey, options: CallHookOptions & {
|
|
500
|
+
environment?: string | EnvironmentContext<any, any>;
|
|
501
|
+
}, ...args: InferHookParameters<PluginContext<any, any>, TKey>) => Promise<InferHookReturnType<PluginContext<any, any>, TKey> | undefined>;
|
|
509
502
|
};
|
|
510
|
-
interface ExecutionContext<TResolvedConfig extends ResolvedConfig = ResolvedConfig> extends Context<TResolvedConfig> {
|
|
503
|
+
interface ExecutionContext<TResolvedConfig extends ResolvedConfig = ResolvedConfig, TSystemContext = unknown> extends Context<TResolvedConfig, TSystemContext> {
|
|
504
|
+
/**
|
|
505
|
+
* The unique identifier of the execution context, which can be used for logging and other purposes to distinguish between different executions in the same process.
|
|
506
|
+
*/
|
|
507
|
+
readonly id: string;
|
|
511
508
|
/**
|
|
512
509
|
* The expected plugins options for the Powerlines project.
|
|
513
510
|
*
|
|
514
511
|
* @remarks
|
|
515
512
|
* This is a record of plugin identifiers to their respective options. This field is populated by the Powerlines engine during both plugin initialization and the `init` command.
|
|
516
513
|
*/
|
|
517
|
-
plugins: Plugin<PluginContext<TResolvedConfig>>[];
|
|
518
|
-
/**
|
|
519
|
-
* A function to add a plugin to the context and update the configuration options
|
|
520
|
-
*/
|
|
521
|
-
addPlugin: (plugin: Plugin<PluginContext<TResolvedConfig>>) => Promise<void>;
|
|
514
|
+
plugins: Plugin<PluginContext<TResolvedConfig, TSystemContext>>[];
|
|
522
515
|
/**
|
|
523
516
|
* A table for storing the current context for each configured environment
|
|
524
517
|
*/
|
|
525
|
-
environments: Record<string, EnvironmentContext<TResolvedConfig>>;
|
|
518
|
+
environments: Record<string, EnvironmentContext<TResolvedConfig, TSystemContext>>;
|
|
526
519
|
/**
|
|
527
520
|
* Retrieves the context for a specific environment by name
|
|
528
521
|
*
|
|
@@ -537,7 +530,7 @@ interface ExecutionContext<TResolvedConfig extends ResolvedConfig = ResolvedConf
|
|
|
537
530
|
* const defaultEnv = await apiContext.getEnvironment();
|
|
538
531
|
* ```
|
|
539
532
|
*/
|
|
540
|
-
getEnvironment: (name?: string) => Promise<EnvironmentContext<TResolvedConfig>>;
|
|
533
|
+
getEnvironment: (name?: string) => Promise<EnvironmentContext<TResolvedConfig, TSystemContext>>;
|
|
541
534
|
/**
|
|
542
535
|
* Safely retrieves the context for a specific environment by name
|
|
543
536
|
*
|
|
@@ -565,87 +558,105 @@ interface ExecutionContext<TResolvedConfig extends ResolvedConfig = ResolvedConf
|
|
|
565
558
|
*
|
|
566
559
|
* Using this method helps avoid unhandled exceptions in cases where an environment might not be defined.
|
|
567
560
|
*/
|
|
568
|
-
getEnvironmentSafe: (name?: string) => Promise<EnvironmentContext<TResolvedConfig> | undefined>;
|
|
561
|
+
getEnvironmentSafe: (name?: string) => Promise<EnvironmentContext<TResolvedConfig, TSystemContext> | undefined>;
|
|
569
562
|
/**
|
|
570
563
|
* A function to copy the context and update the fields for a specific environment
|
|
571
564
|
*
|
|
572
565
|
* @param environment - The environment configuration to use.
|
|
573
566
|
* @returns A new context instance with the updated environment.
|
|
574
567
|
*/
|
|
575
|
-
|
|
568
|
+
createEnvironment: (environment: EnvironmentResolvedConfig<TResolvedConfig>["environment"]) => Promise<EnvironmentContext<TResolvedConfig, TSystemContext>>;
|
|
576
569
|
/**
|
|
577
570
|
* A function to merge all configured environments into a single context
|
|
578
571
|
*
|
|
579
572
|
* @returns A promise that resolves to the merged environment context.
|
|
580
573
|
*/
|
|
581
|
-
toEnvironment: () => Promise<EnvironmentContext<TResolvedConfig>>;
|
|
574
|
+
toEnvironment: () => Promise<EnvironmentContext<TResolvedConfig, TSystemContext>>;
|
|
582
575
|
/**
|
|
583
|
-
* A function to
|
|
576
|
+
* A function used internally to add a plugin to the context and update the configuration options
|
|
584
577
|
*
|
|
585
|
-
* @
|
|
586
|
-
* This
|
|
578
|
+
* @danger
|
|
579
|
+
* This field is for internal use only and should not be accessed or modified directly. It is unstable and can be changed at anytime.
|
|
580
|
+
*
|
|
581
|
+
* @internal
|
|
587
582
|
*/
|
|
588
|
-
|
|
583
|
+
unstable_addPlugin: (plugin: PluginConfig<PluginContext<TResolvedConfig, TSystemContext>>) => Promise<void>;
|
|
589
584
|
}
|
|
590
|
-
interface
|
|
591
|
-
|
|
592
|
-
|
|
585
|
+
interface EnvironmentPlugin<TResolvedConfig extends ResolvedConfig = ResolvedConfig, TSystemContext = unknown> extends Plugin<PluginContext<TResolvedConfig, TSystemContext>> {
|
|
586
|
+
/**
|
|
587
|
+
* A internal field to store the plugin configuration and context for the environment context
|
|
588
|
+
*
|
|
589
|
+
* @danger
|
|
590
|
+
* This field is for internal use only and should not be accessed or modified directly. It is unstable and can be changed at anytime.
|
|
591
|
+
*
|
|
592
|
+
* @internal
|
|
593
|
+
*/
|
|
594
|
+
"~internal": {
|
|
595
|
+
/**
|
|
596
|
+
* The unique identifier of the plugin, which can be used for logging and other purposes to distinguish between different plugins in the same process.
|
|
597
|
+
*/
|
|
598
|
+
readonly id: string;
|
|
599
|
+
/**
|
|
600
|
+
* The context for the plugin, which provides access to the Powerlines engine and other utilities for interacting with the build process.
|
|
601
|
+
*
|
|
602
|
+
* @remarks
|
|
603
|
+
* This context is specific to the plugin and environment, allowing for environment-specific modifications without affecting the global context.
|
|
604
|
+
*/
|
|
605
|
+
readonly context: PluginContext<TResolvedConfig, TSystemContext>;
|
|
606
|
+
};
|
|
593
607
|
}
|
|
594
608
|
type SelectHookResultItem<TContext extends PluginContext, TKey extends string> = HooksListItem<TContext, TKey> & {
|
|
595
609
|
context: TContext;
|
|
596
610
|
};
|
|
597
611
|
type SelectHookResult<TContext extends PluginContext, TKey extends string> = SelectHookResultItem<TContext, TKey>[];
|
|
598
|
-
interface EnvironmentContext<TResolvedConfig extends ResolvedConfig = ResolvedConfig> extends Context<TResolvedConfig> {
|
|
612
|
+
interface EnvironmentContext<TResolvedConfig extends ResolvedConfig = ResolvedConfig, TSystemContext = unknown> extends Context<EnvironmentResolvedConfig<TResolvedConfig>, TSystemContext> {
|
|
613
|
+
/**
|
|
614
|
+
* The unique identifier of the environment associated with this context, which can be used for logging and other purposes to distinguish between different environments in the same process.
|
|
615
|
+
*/
|
|
616
|
+
readonly id: string;
|
|
599
617
|
/**
|
|
600
618
|
* The expected plugins options for the Powerlines project.
|
|
601
619
|
*
|
|
602
620
|
* @remarks
|
|
603
621
|
* This is a record of plugin identifiers to their respective options. This field is populated by the Powerlines engine during both plugin initialization and the `init` command.
|
|
604
622
|
*/
|
|
605
|
-
plugins:
|
|
606
|
-
/**
|
|
607
|
-
* A function to add a plugin to the context and update the configuration options
|
|
608
|
-
*/
|
|
609
|
-
addPlugin: (plugin: Plugin<PluginContext<TResolvedConfig>>) => Promise<void>;
|
|
623
|
+
plugins: EnvironmentPlugin<TResolvedConfig, TSystemContext>[];
|
|
610
624
|
/**
|
|
611
|
-
*
|
|
625
|
+
* A table holding references to hook functions registered by plugins
|
|
612
626
|
*/
|
|
613
|
-
|
|
627
|
+
hooks: HooksList<PluginContext<TResolvedConfig, TSystemContext>>;
|
|
614
628
|
/**
|
|
615
|
-
*
|
|
629
|
+
* The execution context associated with this environment, which provides access to the project configuration, environment, and utility functions for performing the build. The execution context is used to manage the state and behavior of the build process across multiple environments, allowing for hooks to be called at different stages of the build and for environment-specific configurations to be applied.
|
|
630
|
+
*
|
|
631
|
+
* @danger
|
|
632
|
+
* This field is for internal use only and should not be accessed or modified directly. It is unstable and can be changed at anytime.
|
|
633
|
+
*
|
|
634
|
+
* @internal
|
|
616
635
|
*/
|
|
617
|
-
|
|
636
|
+
unstable_execution: ExecutionContext<TResolvedConfig, TSystemContext>;
|
|
618
637
|
/**
|
|
619
638
|
* Retrieves the hook handlers for a specific hook name
|
|
620
639
|
*/
|
|
621
|
-
selectHooks: <TKey extends string>(key: TKey, options?: SelectHooksOptions) => SelectHookResult<PluginContext<TResolvedConfig>, TKey>;
|
|
640
|
+
selectHooks: <TKey extends string>(key: TKey, options?: SelectHooksOptions) => SelectHookResult<PluginContext<TResolvedConfig, TSystemContext>, TKey>;
|
|
622
641
|
/**
|
|
623
|
-
* A function to
|
|
642
|
+
* A function used internally to add a plugin to the context and update the configuration options
|
|
624
643
|
*
|
|
625
|
-
* @
|
|
626
|
-
* This
|
|
644
|
+
* @danger
|
|
645
|
+
* This field is for internal use only and should not be accessed or modified directly. It is unstable and can be changed at anytime.
|
|
646
|
+
*
|
|
647
|
+
* @internal
|
|
627
648
|
*/
|
|
628
|
-
|
|
649
|
+
unstable_addPlugin: (plugin: PluginConfig<PluginContext<TResolvedConfig, TSystemContext>>) => Promise<void>;
|
|
629
650
|
}
|
|
630
|
-
interface PluginContext<out TResolvedConfig extends ResolvedConfig = ResolvedConfig> extends Context<TResolvedConfig>,
|
|
651
|
+
interface PluginContext<out TResolvedConfig extends ResolvedConfig = ResolvedConfig, TSystemContext = unknown> extends Context<EnvironmentResolvedConfig<TResolvedConfig>, TSystemContext> {
|
|
631
652
|
/**
|
|
632
|
-
* The
|
|
653
|
+
* The unique identifier of the plugin associated with this context, which can be used for logging and other purposes to distinguish between different plugins in the same process.
|
|
633
654
|
*/
|
|
634
|
-
|
|
655
|
+
readonly id: string;
|
|
635
656
|
/**
|
|
636
|
-
*
|
|
637
|
-
*
|
|
638
|
-
* @remarks
|
|
639
|
-
* This is provided for compatibility with other logging libraries that expect a `logger` property.
|
|
640
|
-
*/
|
|
641
|
-
logger: LogFn;
|
|
642
|
-
/**
|
|
643
|
-
* A function to create a deep clone of the context
|
|
644
|
-
*
|
|
645
|
-
* @remarks
|
|
646
|
-
* This function is used to create a copy of the context for a specific environment, allowing for environment-specific modifications without affecting the global context.
|
|
657
|
+
* The context for the environment associated with this plugin context, which provides access to the Powerlines engine and other utilities for interacting with the build process. This context is specific to the plugin and environment, allowing for environment-specific modifications without affecting the global context.
|
|
647
658
|
*/
|
|
648
|
-
|
|
659
|
+
readonly environment: EnvironmentContext;
|
|
649
660
|
}
|
|
650
661
|
type BuildPluginContext<TResolvedConfig extends ResolvedConfig = ResolvedConfig> = UnpluginBuildContext & PluginContext<TResolvedConfig>;
|
|
651
662
|
type WithUnpluginBuildContext<TContext extends PluginContext> = UnpluginBuildContext & TContext;
|
|
@@ -662,11 +673,10 @@ declare type __ΩEmitOptions = any[];
|
|
|
662
673
|
declare type __ΩEmitEntryOptions = any[];
|
|
663
674
|
declare type __ΩResolveResult = any[];
|
|
664
675
|
declare type __ΩBaseContext = any[];
|
|
665
|
-
declare type __ΩEngineContext = any[];
|
|
666
676
|
declare type __ΩUnresolvedContext = any[];
|
|
667
677
|
declare type __ΩContext = any[];
|
|
668
678
|
declare type __ΩExecutionContext = any[];
|
|
669
|
-
declare type __Ω
|
|
679
|
+
declare type __ΩEnvironmentPlugin = any[];
|
|
670
680
|
declare type __ΩSelectHookResultItem = any[];
|
|
671
681
|
declare type __ΩSelectHookResult = any[];
|
|
672
682
|
declare type __ΩEnvironmentContext = any[];
|
|
@@ -674,5 +684,5 @@ declare type __ΩPluginContext = any[];
|
|
|
674
684
|
declare type __ΩBuildPluginContext = any[];
|
|
675
685
|
declare type __ΩWithUnpluginBuildContext = any[];
|
|
676
686
|
//#endregion
|
|
677
|
-
export { BaseContext, BuildPluginContext, Context, EmitEntryOptions, EmitOptions,
|
|
687
|
+
export { BaseContext, BuildPluginContext, Context, EmitEntryOptions, EmitOptions, EnvironmentContext, EnvironmentPlugin, ExecutionContext, FetchOptions, InitContextOptions, MetaInfo, ParseOptions, PluginContext, ResolveResult, Resolver, SelectHookResult, SelectHookResultItem, SelectHooksOptions, SourceFile, TransformResult$1 as TransformResult, UnimportContext, UnresolvedContext, WithUnpluginBuildContext, __ΩBaseContext, __ΩBuildPluginContext, __ΩContext, __ΩEmitEntryOptions, __ΩEmitOptions, __ΩEnvironmentContext, __ΩEnvironmentPlugin, __ΩExecutionContext, __ΩFetchOptions, __ΩInitContextOptions, __ΩMetaInfo, __ΩParseOptions, __ΩPluginContext, __ΩResolveResult, __ΩResolver, __ΩSelectHookResult, __ΩSelectHookResultItem, __ΩSelectHooksOptions, __ΩSourceFile, __ΩTransformResult, __ΩUnimportContext, __ΩUnresolvedContext, __ΩWithUnpluginBuildContext };
|
|
678
688
|
//# sourceMappingURL=context.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context.d.mts","names":[],"sources":["../../src/types/context.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"context.d.mts","names":[],"sources":["../../src/types/context.ts"],"mappings":";;;;;;;;;;;;;;;;;;KAsDY,QAAA,GAAW,MAAA;EAAX;;;EAIV,QAAA;EAJqB;;;EASrB,WAAA;EAUA;;;EALA,SAAA;EAeU;AAGZ;;EAbE,SAAA;EAaoC;;;EARpC,QAAA;EASY;;AAGd;EAPE,UAAA;AAAA;AAAA,UAGe,QAAA,SAAiB,IAAA;EAChC,MAAA,EAAQ,IAAA;AAAA;AAAA,UAGO,iBAAA;EACf,IAAA;EACA,GAAA,EAAK,SAAA;AAAA;;;;UAMU,UAAA;EASf;;;EALA,EAAA;EAeS;;;EAVT,IAAA,EAAM,WAAA;EAamB;;;EARzB,GAAA;EASmB;;;EAJnB,MAAA,GAAS,iBAAA;AAAA;AAAA,KAGC,eAAA,GAAkB,IAAA,CAAK,QAAA;EACjC,WAAA,QAAmB,OAAA;EACnB,aAAA,GAAgB,MAAA,EAAQ,UAAA,KAAe,OAAA,CAAQ,UAAA;EAC/C,qBAAA,QAA6B,OAAA;AAAA;AAAA,UAGd,kBAAA;EACf,KAAA;AAAA;;;;UAMe,kBAAA;EAVc;;;AAG/B;;EAaE,cAAA;AAAA;;AANF;;UAYiB,YAAA,SAAqB,mBAAA;E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AAc,QAAA,EAAU,IAAA;EAC1B,OAAA,EAAS,QAAA;AAAA;AAAA,KAGC,gBAAA,kBACO,aAAA,yBAEf,oBAAA,CAAqB,QAAA,EAAU,IAAA;AAAA,UAElB,kBAAA,yBACS,cAAA,GAAiB,cAAA,oCAEjC,OAAA,CAAQ,yBAAA,CAA0B,eAAA,GAAkB,cAAA;EAXnD;;;EAAA,SAeA,EAAA;EAlBQ;;;;;;EA0BjB,OAAA,EAAS,iBAAA,CAAkB,eAAA,EAAiB,cAAA;EAvB3B;;AAGnB;EAyBE,KAAA,EAAO,SAAA,CAAU,aAAA,CAAc,eAAA,EAAiB,cAAA;EAzBtB;;;;;;;;EAmC1B,kBAAA,EAAoB,gBAAA,CAAiB,eAAA,EAAiB,cAAA;EAjCtD;;;EAsCA,WAAA,wBACE,GAAA,EAAK,IAAA,EACL,OAAA,GAAU,kBAAA,KACP,gBAAA,CAAiB,aAAA,CAAc,eAAA,EAAiB,cAAA,GAAiB,IAAA;EAxCjC;;AAEvC;;;;;;EAgDE,kBAAA,GACE,MAAA,EAAQ,YAAA,CAAa,aAAA,CAAc,eAAA,EAAiB,cAAA,OACjD,OAAA;AAAA;AAAA,UAGU,aAAA,6BACa,cAAA,GAAiB,cAAA,oCAErC,OAAA,CAAQ,yBAAA,CAA0B,eAAA,GAAkB,cAAA;EAzChB;;;EAAA,SA6CnC,EAAA;EAxCQ;;;EAAA,SA6CR,WAAA,EAAa,kBAAA;AAAA;AAAA,KAGZ,kBAAA,yBACc,cAAA,GAAiB,cAAA,IACvC,oBAAA,GAAuB,aAAA,CAAc,eAAA;AAAA,KAE7B,wBAAA,kBAA0C,aAAA,IACpD,oBAAA,GAAuB,QAAA;AAAA"}
|
package/dist/types/fs.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { ResolveOptions } from "@stryke/fs/resolve";
|
|
1
2
|
import { MaybePromise } from "@stryke/types/base";
|
|
2
3
|
import { AssetGlob } from "@stryke/types/file";
|
|
3
|
-
import { ResolveOptions } from "@stryke/fs/resolve";
|
|
4
4
|
|
|
5
5
|
//#region src/types/fs.d.ts
|
|
6
6
|
type VirtualFileExtension = "js" | "ts" | "jsx" | "tsx";
|
package/dist/types/index.d.cts
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { ResolveOptions, StorageAdapter, StoragePort, StoragePreset, VirtualFile, VirtualFileData, VirtualFileExtension, VirtualFileMetadata, VirtualFileSystemInterface, WriteData, WriteOptions, __ΩResolveOptions, __ΩStorageAdapter, __ΩStoragePort, __ΩStoragePreset, __ΩVirtualFile, __ΩVirtualFileData, __ΩVirtualFileExtension, __ΩVirtualFileMetadata, __ΩVirtualFileSystemInterface, __ΩWriteData, __ΩWriteOptions } from "./fs.cjs";
|
|
2
|
-
import { BaseCommandType, CommandType, Commands, __ΩBaseCommandType, __ΩCommandType, __ΩCommands } from "./
|
|
3
|
-
import {
|
|
4
|
-
import { API, Engine, Execution, ExecutionWorkerParams, ExecutionWorkerProcess, __ΩAPI, __ΩEngine, __ΩExecution, __ΩExecutionWorkerParams, __ΩExecutionWorkerProcess } from "./api.cjs";
|
|
5
|
-
import { BuilderVariant, InferUnpluginOptions, InferUnpluginVariant, UnpluginAsyncFactory, UnpluginBuilderVariant, UnpluginFactory, UnpluginHookFunctions, UnpluginOptions, UnpluginUserConfig, __ΩBuilderVariant, __ΩInferUnpluginOptions, __ΩInferUnpluginVariant, __ΩUnpluginAsyncFactory, __ΩUnpluginBuilderVariant, __ΩUnpluginFactory, __ΩUnpluginHookFunctions, __ΩUnpluginOptions, __ΩUnpluginUserConfig } from "./unplugin.cjs";
|
|
2
|
+
import { BaseCommandType, BaseExecutionAPIMethods, CommandType, Commands, PowerlinesExecutionAPIMethods, SupportedCommands, __ΩBaseCommandType, __ΩBaseExecutionAPIMethods, __ΩCommandType, __ΩCommands, __ΩPowerlinesExecutionAPIMethods, __ΩSupportedCommands } from "./api.cjs";
|
|
3
|
+
import { BuilderVariant, UnpluginBuilderVariant, UnpluginHookFunctions, UnpluginOptions, __ΩBuilderVariant, __ΩUnpluginBuilderVariant, __ΩUnpluginHookFunctions, __ΩUnpluginOptions } from "./unplugin.cjs";
|
|
6
4
|
import { BasePlugin, HookFunctions, Hooks, Plugin, PluginHook, PluginHookFields, PluginHookObject, PluginHooks, PluginNonHookFields, TypesResult, __ΩBasePlugin, __ΩHookFunctions, __ΩHooks, __ΩPlugin, __ΩPluginHook, __ΩPluginHookFields, __ΩPluginHookObject, __ΩPluginHooks, __ΩPluginNonHookFields, __ΩTypesResult } from "./plugin.cjs";
|
|
7
5
|
import { CallHookOptions, HookListOrders, HooksList, HooksListItem, InferHookFunction, InferHookParameters, InferHookReturnType, InferHookThisType, NormalizedStringFilter, PluginFilter, TransformHookFilter, __ΩCallHookOptions, __ΩHookListOrders, __ΩHooksList, __ΩHooksListItem, __ΩInferHookFunction, __ΩInferHookParameters, __ΩInferHookReturnType, __ΩInferHookThisType, __ΩNormalizedStringFilter, __ΩPluginFilter, __ΩTransformHookFilter } from "./hooks.cjs";
|
|
6
|
+
import { CustomLogger, CustomLoggerMessage, LogCategory, LogFn, LogFnMeta, LogFnOptions, LogLevel, LogLevelResolvedConfig, LogLevelUserConfig, LogMessage, LogMeta, Logger, LoggerMessage, LoggerMeta, LoggerOptions, PowerlinesMessage, __ΩCustomLogger, __ΩCustomLoggerMessage, __ΩLogCategory, __ΩLogFn, __ΩLogFnMeta, __ΩLogFnOptions, __ΩLogLevel, __ΩLogLevelResolvedConfig, __ΩLogLevelUserConfig, __ΩLogMessage, __ΩLogMeta, __ΩLogger, __ΩLoggerMessage, __ΩLoggerMeta, __ΩLoggerOptions, __ΩPowerlinesMessage } from "./logging.cjs";
|
|
8
7
|
import { DeepkitOptions, Level, ParsedTypeScriptConfig, RawReflectionMode, ReflectionMode, TSCompilerOptions, TSConfig, __ΩDeepkitOptions, __ΩLevel, __ΩParsedTypeScriptConfig, __ΩRawReflectionMode, __ΩReflectionMode, __ΩTSCompilerOptions, __ΩTSConfig } from "./tsconfig.cjs";
|
|
9
|
-
import { BaseContext, BuildPluginContext, Context, EmitEntryOptions, EmitOptions,
|
|
10
|
-
import { AnyOutputUserConfig, AnyUserConfig, BuildInlineConfig, CleanInlineConfig, Config, CopyConfig,
|
|
8
|
+
import { BaseContext, BuildPluginContext, Context, EmitEntryOptions, EmitOptions, EnvironmentContext, EnvironmentPlugin, ExecutionContext, FetchOptions, InitContextOptions, MetaInfo, ParseOptions, PluginContext, ResolveResult, Resolver, SelectHookResult, SelectHookResultItem, SelectHooksOptions, SourceFile, TransformResult, UnimportContext, UnresolvedContext, WithUnpluginBuildContext, __ΩBaseContext, __ΩBuildPluginContext, __ΩContext, __ΩEmitEntryOptions, __ΩEmitOptions, __ΩEnvironmentContext, __ΩEnvironmentPlugin, __ΩExecutionContext, __ΩFetchOptions, __ΩInitContextOptions, __ΩMetaInfo, __ΩParseOptions, __ΩPluginContext, __ΩResolveResult, __ΩResolver, __ΩSelectHookResult, __ΩSelectHookResultItem, __ΩSelectHooksOptions, __ΩSourceFile, __ΩTransformResult, __ΩUnimportContext, __ΩUnresolvedContext, __ΩWithUnpluginBuildContext } from "./context.cjs";
|
|
9
|
+
import { AnyOutputUserConfig, AnyUserConfig, BaseExecutionOptions, BuildInlineConfig, CleanInlineConfig, Config, ConfigParams, CopyConfig, CreateInlineConfig, DeployInlineConfig, DocsInlineConfig, EnvironmentConfig, EnvironmentResolvedConfig, ExecutionOptions, FrameworkOptions, InferOverridableConfig, InlineConfig, InlineConfigPaths, LintInlineConfig, Mode, Options, OutputConfig, ParsedUserConfig, PartialPlugin, PartialPluginFactory, PluginConfig, PluginConfigObject, PluginConfigTuple, PluginFactory, PowerlinesCommand, PrepareInlineConfig, ProjectType, ResolveConfig, ResolvedAssetGlob, ResolvedConfig, ResolvedCopyConfig, ResolvedEntryTypeDefinition, ResolvedEnvironmentConfig, ResolvedOutputConfig, ResolvedResolveConfig, TestInlineConfig, TypesInlineConfig, UserConfig, UserConfigFn, WorkspaceConfig, __ΩAnyOutputUserConfig, __ΩAnyUserConfig, __ΩBaseExecutionOptions, __ΩBuildInlineConfig, __ΩCleanInlineConfig, __ΩConfig, __ΩConfigParams, __ΩCopyConfig, __ΩCreateInlineConfig, __ΩDeployInlineConfig, __ΩDocsInlineConfig, __ΩEnvironmentConfig, __ΩEnvironmentResolvedConfig, __ΩExecutionOptions, __ΩFrameworkOptions, __ΩInferOverridableConfig, __ΩInlineConfig, __ΩInlineConfigPaths, __ΩLintInlineConfig, __ΩMode, __ΩOptions, __ΩOutputConfig, __ΩParsedUserConfig, __ΩPartialPlugin, __ΩPartialPluginFactory, __ΩPluginConfig, __ΩPluginConfigObject, __ΩPluginConfigTuple, __ΩPluginFactory, __ΩPowerlinesCommand, __ΩPrepareInlineConfig, __ΩProjectType, __ΩResolveConfig, __ΩResolvedAssetGlob, __ΩResolvedConfig, __ΩResolvedCopyConfig, __ΩResolvedEntryTypeDefinition, __ΩResolvedEnvironmentConfig, __ΩResolvedOutputConfig, __ΩResolvedResolveConfig, __ΩTestInlineConfig, __ΩTypesInlineConfig, __ΩUserConfig, __ΩUserConfigFn, __ΩWorkspaceConfig } from "./config.cjs";
|
package/dist/types/index.d.mts
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { ResolveOptions, StorageAdapter, StoragePort, StoragePreset, VirtualFile, VirtualFileData, VirtualFileExtension, VirtualFileMetadata, VirtualFileSystemInterface, WriteData, WriteOptions, __ΩResolveOptions, __ΩStorageAdapter, __ΩStoragePort, __ΩStoragePreset, __ΩVirtualFile, __ΩVirtualFileData, __ΩVirtualFileExtension, __ΩVirtualFileMetadata, __ΩVirtualFileSystemInterface, __ΩWriteData, __ΩWriteOptions } from "./fs.mjs";
|
|
2
|
-
import { BaseCommandType, CommandType, Commands, __ΩBaseCommandType, __ΩCommandType, __ΩCommands } from "./
|
|
3
|
-
import {
|
|
4
|
-
import { API, Engine, Execution, ExecutionWorkerParams, ExecutionWorkerProcess, __ΩAPI, __ΩEngine, __ΩExecution, __ΩExecutionWorkerParams, __ΩExecutionWorkerProcess } from "./api.mjs";
|
|
5
|
-
import { BuilderVariant, InferUnpluginOptions, InferUnpluginVariant, UnpluginAsyncFactory, UnpluginBuilderVariant, UnpluginFactory, UnpluginHookFunctions, UnpluginOptions, UnpluginUserConfig, __ΩBuilderVariant, __ΩInferUnpluginOptions, __ΩInferUnpluginVariant, __ΩUnpluginAsyncFactory, __ΩUnpluginBuilderVariant, __ΩUnpluginFactory, __ΩUnpluginHookFunctions, __ΩUnpluginOptions, __ΩUnpluginUserConfig } from "./unplugin.mjs";
|
|
2
|
+
import { BaseCommandType, BaseExecutionAPIMethods, CommandType, Commands, PowerlinesExecutionAPIMethods, SupportedCommands, __ΩBaseCommandType, __ΩBaseExecutionAPIMethods, __ΩCommandType, __ΩCommands, __ΩPowerlinesExecutionAPIMethods, __ΩSupportedCommands } from "./api.mjs";
|
|
3
|
+
import { BuilderVariant, UnpluginBuilderVariant, UnpluginHookFunctions, UnpluginOptions, __ΩBuilderVariant, __ΩUnpluginBuilderVariant, __ΩUnpluginHookFunctions, __ΩUnpluginOptions } from "./unplugin.mjs";
|
|
6
4
|
import { BasePlugin, HookFunctions, Hooks, Plugin, PluginHook, PluginHookFields, PluginHookObject, PluginHooks, PluginNonHookFields, TypesResult, __ΩBasePlugin, __ΩHookFunctions, __ΩHooks, __ΩPlugin, __ΩPluginHook, __ΩPluginHookFields, __ΩPluginHookObject, __ΩPluginHooks, __ΩPluginNonHookFields, __ΩTypesResult } from "./plugin.mjs";
|
|
7
5
|
import { CallHookOptions, HookListOrders, HooksList, HooksListItem, InferHookFunction, InferHookParameters, InferHookReturnType, InferHookThisType, NormalizedStringFilter, PluginFilter, TransformHookFilter, __ΩCallHookOptions, __ΩHookListOrders, __ΩHooksList, __ΩHooksListItem, __ΩInferHookFunction, __ΩInferHookParameters, __ΩInferHookReturnType, __ΩInferHookThisType, __ΩNormalizedStringFilter, __ΩPluginFilter, __ΩTransformHookFilter } from "./hooks.mjs";
|
|
6
|
+
import { CustomLogger, CustomLoggerMessage, LogCategory, LogFn, LogFnMeta, LogFnOptions, LogLevel, LogLevelResolvedConfig, LogLevelUserConfig, LogMessage, LogMeta, Logger, LoggerMessage, LoggerMeta, LoggerOptions, PowerlinesMessage, __ΩCustomLogger, __ΩCustomLoggerMessage, __ΩLogCategory, __ΩLogFn, __ΩLogFnMeta, __ΩLogFnOptions, __ΩLogLevel, __ΩLogLevelResolvedConfig, __ΩLogLevelUserConfig, __ΩLogMessage, __ΩLogMeta, __ΩLogger, __ΩLoggerMessage, __ΩLoggerMeta, __ΩLoggerOptions, __ΩPowerlinesMessage } from "./logging.mjs";
|
|
8
7
|
import { DeepkitOptions, Level, ParsedTypeScriptConfig, RawReflectionMode, ReflectionMode, TSCompilerOptions, TSConfig, __ΩDeepkitOptions, __ΩLevel, __ΩParsedTypeScriptConfig, __ΩRawReflectionMode, __ΩReflectionMode, __ΩTSCompilerOptions, __ΩTSConfig } from "./tsconfig.mjs";
|
|
9
|
-
import { BaseContext, BuildPluginContext, Context, EmitEntryOptions, EmitOptions,
|
|
10
|
-
import { AnyOutputUserConfig, AnyUserConfig, BuildInlineConfig, CleanInlineConfig, Config, CopyConfig,
|
|
8
|
+
import { BaseContext, BuildPluginContext, Context, EmitEntryOptions, EmitOptions, EnvironmentContext, EnvironmentPlugin, ExecutionContext, FetchOptions, InitContextOptions, MetaInfo, ParseOptions, PluginContext, ResolveResult, Resolver, SelectHookResult, SelectHookResultItem, SelectHooksOptions, SourceFile, TransformResult, UnimportContext, UnresolvedContext, WithUnpluginBuildContext, __ΩBaseContext, __ΩBuildPluginContext, __ΩContext, __ΩEmitEntryOptions, __ΩEmitOptions, __ΩEnvironmentContext, __ΩEnvironmentPlugin, __ΩExecutionContext, __ΩFetchOptions, __ΩInitContextOptions, __ΩMetaInfo, __ΩParseOptions, __ΩPluginContext, __ΩResolveResult, __ΩResolver, __ΩSelectHookResult, __ΩSelectHookResultItem, __ΩSelectHooksOptions, __ΩSourceFile, __ΩTransformResult, __ΩUnimportContext, __ΩUnresolvedContext, __ΩWithUnpluginBuildContext } from "./context.mjs";
|
|
9
|
+
import { AnyOutputUserConfig, AnyUserConfig, BaseExecutionOptions, BuildInlineConfig, CleanInlineConfig, Config, ConfigParams, CopyConfig, CreateInlineConfig, DeployInlineConfig, DocsInlineConfig, EnvironmentConfig, EnvironmentResolvedConfig, ExecutionOptions, FrameworkOptions, InferOverridableConfig, InlineConfig, InlineConfigPaths, LintInlineConfig, Mode, Options, OutputConfig, ParsedUserConfig, PartialPlugin, PartialPluginFactory, PluginConfig, PluginConfigObject, PluginConfigTuple, PluginFactory, PowerlinesCommand, PrepareInlineConfig, ProjectType, ResolveConfig, ResolvedAssetGlob, ResolvedConfig, ResolvedCopyConfig, ResolvedEntryTypeDefinition, ResolvedEnvironmentConfig, ResolvedOutputConfig, ResolvedResolveConfig, TestInlineConfig, TypesInlineConfig, UserConfig, UserConfigFn, WorkspaceConfig, __ΩAnyOutputUserConfig, __ΩAnyUserConfig, __ΩBaseExecutionOptions, __ΩBuildInlineConfig, __ΩCleanInlineConfig, __ΩConfig, __ΩConfigParams, __ΩCopyConfig, __ΩCreateInlineConfig, __ΩDeployInlineConfig, __ΩDocsInlineConfig, __ΩEnvironmentConfig, __ΩEnvironmentResolvedConfig, __ΩExecutionOptions, __ΩFrameworkOptions, __ΩInferOverridableConfig, __ΩInlineConfig, __ΩInlineConfigPaths, __ΩLintInlineConfig, __ΩMode, __ΩOptions, __ΩOutputConfig, __ΩParsedUserConfig, __ΩPartialPlugin, __ΩPartialPluginFactory, __ΩPluginConfig, __ΩPluginConfigObject, __ΩPluginConfigTuple, __ΩPluginFactory, __ΩPowerlinesCommand, __ΩPrepareInlineConfig, __ΩProjectType, __ΩResolveConfig, __ΩResolvedAssetGlob, __ΩResolvedConfig, __ΩResolvedCopyConfig, __ΩResolvedEntryTypeDefinition, __ΩResolvedEnvironmentConfig, __ΩResolvedOutputConfig, __ΩResolvedResolveConfig, __ΩTestInlineConfig, __ΩTypesInlineConfig, __ΩUserConfig, __ΩUserConfigFn, __ΩWorkspaceConfig } from "./config.mjs";
|