@powerlines/core 0.48.32 → 0.48.33
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/{chunk-C_NdSu1c.cjs → _virtual/_rolldown/runtime.cjs} +1 -6
- package/dist/constants/api.d.cts +6 -2
- package/dist/constants/api.d.cts.map +1 -0
- package/dist/constants/api.d.mts +6 -2
- package/dist/constants/api.d.mts.map +1 -0
- package/dist/constants/commands.d.cts +5 -2
- package/dist/constants/commands.d.cts.map +1 -0
- package/dist/constants/commands.d.mts +5 -2
- package/dist/constants/commands.d.mts.map +1 -0
- package/dist/constants/devtools.d.cts +13 -2
- package/dist/constants/devtools.d.cts.map +1 -0
- package/dist/constants/devtools.d.mts +13 -2
- package/dist/constants/devtools.d.mts.map +1 -0
- package/dist/constants/environments.d.cts +10 -2
- package/dist/constants/environments.d.cts.map +1 -0
- package/dist/constants/environments.d.mts +10 -2
- package/dist/constants/environments.d.mts.map +1 -0
- package/dist/constants/extensions.d.cts +5 -2
- package/dist/constants/extensions.d.cts.map +1 -0
- package/dist/constants/extensions.d.mts +5 -2
- package/dist/constants/extensions.d.mts.map +1 -0
- package/dist/constants/fs.d.cts +7 -2
- package/dist/constants/fs.d.cts.map +1 -0
- package/dist/constants/fs.d.mts +7 -2
- package/dist/constants/fs.d.mts.map +1 -0
- package/dist/constants/hooks.d.cts +5 -2
- package/dist/constants/hooks.d.cts.map +1 -0
- package/dist/constants/hooks.d.mts +5 -2
- package/dist/constants/hooks.d.mts.map +1 -0
- package/dist/constants/index.d.cts +10 -10
- package/dist/constants/index.d.mts +10 -10
- package/dist/constants/log-level.d.cts +67 -2
- package/dist/constants/log-level.d.cts.map +1 -0
- package/dist/constants/log-level.d.mts +67 -2
- package/dist/constants/log-level.d.mts.map +1 -0
- package/dist/constants/meta.d.cts +6 -2
- package/dist/constants/meta.d.cts.map +1 -0
- package/dist/constants/meta.d.mts +6 -2
- package/dist/constants/meta.d.mts.map +1 -0
- package/dist/constants/plugin.d.cts +9 -2
- package/dist/constants/plugin.d.cts.map +1 -0
- package/dist/constants/plugin.d.mts +9 -2
- package/dist/constants/plugin.d.mts.map +1 -0
- package/dist/context/base-context.cjs +2 -2
- package/dist/context/base-context.d.cts +81 -2
- package/dist/context/base-context.d.cts.map +1 -0
- package/dist/context/base-context.d.mts +81 -2
- package/dist/context/base-context.d.mts.map +1 -0
- package/dist/context/context.cjs +2 -2
- package/dist/context/context.d.cts +373 -2
- package/dist/context/context.d.cts.map +1 -0
- package/dist/context/context.d.mts +373 -2
- package/dist/context/context.d.mts.map +1 -0
- package/dist/context/environment-context.d.cts +5 -2
- package/dist/context/environment-context.d.cts.map +1 -1
- package/dist/context/environment-context.d.mts +5 -2
- package/dist/context/environment-context.d.mts.map +1 -1
- package/dist/context/execution-context.cjs +2 -2
- package/dist/context/execution-context.d.cts +6 -2
- package/dist/context/execution-context.d.cts.map +1 -1
- package/dist/context/execution-context.d.mts +6 -2
- package/dist/context/execution-context.d.mts.map +1 -1
- package/dist/context/index.d.cts +2 -2
- package/dist/context/index.d.mts +2 -2
- package/dist/context/plugin-context.d.cts +3 -1
- package/dist/context/plugin-context.d.cts.map +1 -1
- package/dist/context/plugin-context.d.mts +3 -1
- package/dist/context/plugin-context.d.mts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +32 -24
- package/dist/index.d.mts +32 -24
- package/dist/index.mjs +1 -1
- package/dist/lib/config.cjs +2 -2
- package/dist/lib/config.d.cts +140 -2
- package/dist/lib/config.d.cts.map +1 -0
- package/dist/lib/config.d.mts +140 -2
- package/dist/lib/config.d.mts.map +1 -0
- package/dist/lib/context-helpers.d.cts +16 -2
- package/dist/lib/context-helpers.d.cts.map +1 -0
- package/dist/lib/context-helpers.d.mts +16 -2
- package/dist/lib/context-helpers.d.mts.map +1 -0
- package/dist/lib/entry.d.cts +47 -2
- package/dist/lib/entry.d.cts.map +1 -0
- package/dist/lib/entry.d.mts +47 -2
- package/dist/lib/entry.d.mts.map +1 -0
- package/dist/lib/environment.cjs +2 -2
- package/dist/lib/environment.d.cts +2 -1
- package/dist/lib/environment.d.cts.map +1 -1
- package/dist/lib/environment.d.mts +2 -1
- package/dist/lib/environment.d.mts.map +1 -1
- package/dist/lib/events.d.cts +10 -2
- package/dist/lib/events.d.cts.map +1 -0
- package/dist/lib/events.d.mts +10 -2
- package/dist/lib/events.d.mts.map +1 -0
- package/dist/lib/generate-types.d.cts +66 -2
- package/dist/lib/generate-types.d.cts.map +1 -0
- package/dist/lib/generate-types.d.mts +66 -2
- package/dist/lib/generate-types.d.mts.map +1 -0
- package/dist/lib/hooks.cjs +2 -2
- package/dist/lib/hooks.d.cts +28 -2
- package/dist/lib/hooks.d.cts.map +1 -0
- package/dist/lib/hooks.d.mts +28 -2
- package/dist/lib/hooks.d.mts.map +1 -0
- package/dist/lib/index.cjs +1 -1
- package/dist/lib/index.d.cts +23 -23
- package/dist/lib/index.d.mts +23 -23
- package/dist/lib/index.mjs +1 -1
- package/dist/lib/install-dependencies.d.cts +12 -2
- package/dist/lib/install-dependencies.d.cts.map +1 -0
- package/dist/lib/install-dependencies.d.mts +12 -2
- package/dist/lib/install-dependencies.d.mts.map +1 -0
- package/dist/lib/meta.d.cts +33 -2
- package/dist/lib/meta.d.cts.map +1 -0
- package/dist/lib/meta.d.mts +33 -2
- package/dist/lib/meta.d.mts.map +1 -0
- package/dist/lib/plugins.cjs +2 -2
- package/dist/lib/plugins.d.cts +39 -2
- package/dist/lib/plugins.d.cts.map +1 -0
- package/dist/lib/plugins.d.mts +39 -2
- package/dist/lib/plugins.d.mts.map +1 -0
- package/dist/lib/resolver.cjs +2 -2
- package/dist/lib/resolver.d.cts +20 -2
- package/dist/lib/resolver.d.cts.map +1 -0
- package/dist/lib/resolver.d.mts +20 -2
- package/dist/lib/resolver.d.mts.map +1 -0
- package/dist/lib/schemas.cjs +1 -1
- package/dist/lib/schemas.d.cts +1 -1
- package/dist/lib/schemas.d.mts +1 -1
- package/dist/lib/schemas.mjs +1 -1
- package/dist/lib/streaming-channel.d.cts +126 -2
- package/dist/lib/streaming-channel.d.cts.map +1 -0
- package/dist/lib/streaming-channel.d.mts +126 -2
- package/dist/lib/streaming-channel.d.mts.map +1 -0
- package/dist/lib/typescript/index.d.cts +2 -2
- package/dist/lib/typescript/index.d.mts +2 -2
- package/dist/lib/typescript/ts-morph.cjs +2 -2
- package/dist/lib/typescript/ts-morph.d.cts +38 -2
- package/dist/lib/typescript/ts-morph.d.cts.map +1 -0
- package/dist/lib/typescript/ts-morph.d.mts +38 -2
- package/dist/lib/typescript/ts-morph.d.mts.map +1 -0
- package/dist/lib/typescript/tsconfig.cjs +4 -4
- package/dist/lib/typescript/tsconfig.d.cts +77 -2
- package/dist/lib/typescript/tsconfig.d.cts.map +1 -0
- package/dist/lib/typescript/tsconfig.d.mts +77 -2
- package/dist/lib/typescript/tsconfig.d.mts.map +1 -0
- package/dist/lib/unplugin/helpers.d.cts +23 -2
- package/dist/lib/unplugin/helpers.d.cts.map +1 -0
- package/dist/lib/unplugin/helpers.d.mts +23 -2
- package/dist/lib/unplugin/helpers.d.mts.map +1 -0
- package/dist/lib/unplugin/index.d.cts +3 -3
- package/dist/lib/unplugin/index.d.mts +3 -3
- package/dist/lib/unplugin/module-resolution.cjs +2 -2
- package/dist/lib/unplugin/module-resolution.d.cts +41 -2
- package/dist/lib/unplugin/module-resolution.d.cts.map +1 -0
- package/dist/lib/unplugin/module-resolution.d.mts +41 -2
- package/dist/lib/unplugin/module-resolution.d.mts.map +1 -0
- package/dist/lib/unplugin/plugin.d.cts +40 -2
- package/dist/lib/unplugin/plugin.d.cts.map +1 -0
- package/dist/lib/unplugin/plugin.d.mts +40 -2
- package/dist/lib/unplugin/plugin.d.mts.map +1 -0
- package/dist/lib/utilities/file-header.d.cts +41 -2
- package/dist/lib/utilities/file-header.d.cts.map +1 -0
- package/dist/lib/utilities/file-header.d.mts +41 -2
- package/dist/lib/utilities/file-header.d.mts.map +1 -0
- package/dist/lib/utilities/format.cjs +2 -2
- package/dist/lib/utilities/format.d.cts +24 -2
- package/dist/lib/utilities/format.d.cts.map +1 -0
- package/dist/lib/utilities/format.d.mts +24 -2
- package/dist/lib/utilities/format.d.mts.map +1 -0
- package/dist/lib/utilities/index.d.cts +5 -5
- package/dist/lib/utilities/index.d.mts +5 -5
- package/dist/lib/utilities/source-file.cjs +2 -2
- package/dist/lib/utilities/source-file.d.cts +30 -2
- package/dist/lib/utilities/source-file.d.cts.map +1 -0
- package/dist/lib/utilities/source-file.d.mts +30 -2
- package/dist/lib/utilities/source-file.d.mts.map +1 -0
- package/dist/lib/utilities/source-map.cjs +2 -2
- package/dist/lib/utilities/source-map.d.cts +16 -2
- package/dist/lib/utilities/source-map.d.cts.map +1 -0
- package/dist/lib/utilities/source-map.d.mts +16 -2
- package/dist/lib/utilities/source-map.d.mts.map +1 -0
- package/dist/lib/utilities/write-file.d.cts +15 -2
- package/dist/lib/utilities/write-file.d.cts.map +1 -0
- package/dist/lib/utilities/write-file.d.mts +15 -2
- package/dist/lib/utilities/write-file.d.mts.map +1 -0
- package/dist/lib/vfs.cjs +3 -3
- package/dist/lib/vfs.d.cts +321 -2
- package/dist/lib/vfs.d.cts.map +1 -0
- package/dist/lib/vfs.d.mts +321 -2
- package/dist/lib/vfs.d.mts.map +1 -0
- package/dist/lib/vfs.mjs +1 -1
- package/dist/plugin-base.d.cts +3 -1
- package/dist/plugin-base.d.cts.map +1 -1
- package/dist/plugin-base.d.mts +3 -1
- package/dist/plugin-base.d.mts.map +1 -1
- package/dist/plugin-utils/build-helpers.d.cts +2 -1
- package/dist/plugin-utils/build-helpers.d.cts.map +1 -1
- package/dist/plugin-utils/build-helpers.d.mts +2 -1
- package/dist/plugin-utils/build-helpers.d.mts.map +1 -1
- package/dist/plugin-utils/combine-plugins.d.cts +1 -1
- package/dist/plugin-utils/combine-plugins.d.mts +1 -1
- package/dist/plugin-utils/context-helpers.d.cts +1 -1
- package/dist/plugin-utils/context-helpers.d.mts +1 -1
- package/dist/plugin-utils/enable-plugin.d.cts +2 -1
- package/dist/plugin-utils/enable-plugin.d.cts.map +1 -1
- package/dist/plugin-utils/enable-plugin.d.mts +2 -1
- package/dist/plugin-utils/enable-plugin.d.mts.map +1 -1
- package/dist/plugin-utils/extend.d.cts +3 -1
- package/dist/plugin-utils/extend.d.cts.map +1 -1
- package/dist/plugin-utils/extend.d.mts +3 -1
- package/dist/plugin-utils/extend.d.mts.map +1 -1
- package/dist/plugin-utils/filter.cjs +2 -2
- package/dist/plugin-utils/filter.d.cts +1 -1
- package/dist/plugin-utils/filter.d.mts +1 -1
- package/dist/plugin-utils/format-package-json.d.cts +1 -1
- package/dist/plugin-utils/format-package-json.d.mts +1 -1
- package/dist/plugin-utils/get-config-path.d.cts +1 -1
- package/dist/plugin-utils/get-config-path.d.mts +1 -1
- package/dist/plugin-utils/helpers.d.cts +5 -1
- package/dist/plugin-utils/helpers.d.cts.map +1 -1
- package/dist/plugin-utils/helpers.d.mts +5 -1
- package/dist/plugin-utils/helpers.d.mts.map +1 -1
- package/dist/plugin-utils/install.d.cts +1 -1
- package/dist/plugin-utils/install.d.mts +1 -1
- package/dist/plugin-utils/logging.cjs +2 -2
- package/dist/plugin-utils/logging.d.cts +3 -1
- package/dist/plugin-utils/logging.d.cts.map +1 -1
- package/dist/plugin-utils/logging.d.mts +3 -1
- package/dist/plugin-utils/logging.d.mts.map +1 -1
- package/dist/plugin-utils/merge.cjs +2 -2
- package/dist/plugin-utils/merge.d.cts +3 -1
- package/dist/plugin-utils/merge.d.cts.map +1 -1
- package/dist/plugin-utils/merge.d.mts +3 -1
- package/dist/plugin-utils/merge.d.mts.map +1 -1
- package/dist/plugin-utils/modules.d.cts +1 -1
- package/dist/plugin-utils/modules.d.mts +1 -1
- package/dist/plugin-utils/paths.d.cts +1 -1
- package/dist/plugin-utils/paths.d.mts +1 -1
- package/dist/{fs-C2lru696.cjs → schemas/fs.cjs} +8 -38
- package/dist/{schemas-Zvqwdrw_.d.mts → schemas/fs.d.cts} +2 -2
- package/dist/schemas/fs.d.cts.map +1 -0
- package/dist/{schemas-Zvqwdrw_.d.cts → schemas/fs.d.mts} +2 -2
- package/dist/schemas/fs.d.mts.map +1 -0
- package/dist/{fs-DqLn15uU.mjs → schemas/fs.mjs} +2 -2
- package/dist/schemas/fs.mjs.map +1 -0
- package/dist/storage/base.d.cts +2 -1
- package/dist/storage/base.d.cts.map +1 -1
- package/dist/storage/base.d.mts +2 -1
- package/dist/storage/base.d.mts.map +1 -1
- package/dist/storage/file-system.d.cts +1 -1
- package/dist/storage/file-system.d.mts +1 -1
- package/dist/storage/virtual.d.cts +1 -1
- package/dist/storage/virtual.d.mts +1 -1
- package/dist/types/api.d.cts +16 -0
- package/dist/types/api.d.cts.map +1 -0
- package/dist/types/api.d.mts +16 -0
- package/dist/types/api.d.mts.map +1 -0
- package/dist/types/config.d.cts +739 -0
- package/dist/types/config.d.cts.map +1 -0
- package/dist/types/config.d.mts +739 -0
- package/dist/types/config.d.mts.map +1 -0
- package/dist/types/context.d.cts +682 -0
- package/dist/types/context.d.cts.map +1 -0
- package/dist/types/context.d.mts +682 -0
- package/dist/types/context.d.mts.map +1 -0
- package/dist/types/fs.d.cts +538 -0
- package/dist/types/fs.d.cts.map +1 -0
- package/dist/types/fs.d.mts +538 -0
- package/dist/types/fs.d.mts.map +1 -0
- package/dist/types/hooks.d.cts +96 -0
- package/dist/types/hooks.d.cts.map +1 -0
- package/dist/types/hooks.d.mts +96 -0
- package/dist/types/hooks.d.mts.map +1 -0
- package/dist/types/index.d.cts +9 -0
- package/dist/types/index.d.mts +9 -0
- package/dist/types/logging.d.cts +145 -0
- package/dist/types/logging.d.cts.map +1 -0
- package/dist/types/logging.d.mts +145 -0
- package/dist/types/logging.d.mts.map +1 -0
- package/dist/types/plugin.d.cts +207 -0
- package/dist/types/plugin.d.cts.map +1 -0
- package/dist/types/plugin.d.mts +207 -0
- package/dist/types/plugin.d.mts.map +1 -0
- package/dist/types/tsconfig.d.cts +73 -0
- package/dist/types/tsconfig.d.cts.map +1 -0
- package/dist/types/tsconfig.d.mts +73 -0
- package/dist/types/tsconfig.d.mts.map +1 -0
- package/dist/types/unplugin.d.cts +22 -0
- package/dist/types/unplugin.d.cts.map +1 -0
- package/dist/types/unplugin.d.mts +22 -0
- package/dist/types/unplugin.d.mts.map +1 -0
- package/package.json +7 -7
- package/dist/api-DTCbbtSH.d.cts +0 -6
- package/dist/api-DTCbbtSH.d.cts.map +0 -1
- package/dist/api-DTCbbtSH.d.mts +0 -6
- package/dist/api-DTCbbtSH.d.mts.map +0 -1
- package/dist/base-context-BmxgDD3S.d.mts +0 -79
- package/dist/base-context-BmxgDD3S.d.mts.map +0 -1
- package/dist/base-context-mHoSEqHf.d.cts +0 -79
- package/dist/base-context-mHoSEqHf.d.cts.map +0 -1
- package/dist/commands-DzGd8pnR.d.cts +0 -5
- package/dist/commands-DzGd8pnR.d.cts.map +0 -1
- package/dist/commands-DzGd8pnR.d.mts +0 -5
- package/dist/commands-DzGd8pnR.d.mts.map +0 -1
- package/dist/config-BnV_o0Es.d.cts +0 -2461
- package/dist/config-BnV_o0Es.d.cts.map +0 -1
- package/dist/config-DKeDSykZ.d.cts +0 -138
- package/dist/config-DKeDSykZ.d.cts.map +0 -1
- package/dist/config-DbOP5nVu.d.mts +0 -138
- package/dist/config-DbOP5nVu.d.mts.map +0 -1
- package/dist/config-DboKmDhl.d.mts +0 -2461
- package/dist/config-DboKmDhl.d.mts.map +0 -1
- package/dist/context-C6oL3mPw.d.mts +0 -368
- package/dist/context-C6oL3mPw.d.mts.map +0 -1
- package/dist/context-DcY6YqBQ.d.cts +0 -368
- package/dist/context-DcY6YqBQ.d.cts.map +0 -1
- package/dist/context-helpers-BRt-Eq-v.d.mts +0 -15
- package/dist/context-helpers-BRt-Eq-v.d.mts.map +0 -1
- package/dist/context-helpers-Cnsku6fQ.d.cts +0 -15
- package/dist/context-helpers-Cnsku6fQ.d.cts.map +0 -1
- package/dist/devtools-h0du-bSj.d.cts +0 -13
- package/dist/devtools-h0du-bSj.d.cts.map +0 -1
- package/dist/devtools-h0du-bSj.d.mts +0 -13
- package/dist/devtools-h0du-bSj.d.mts.map +0 -1
- package/dist/entry-BC_V2K2U.d.cts +0 -46
- package/dist/entry-BC_V2K2U.d.cts.map +0 -1
- package/dist/entry-CHIaWcmk.d.mts +0 -46
- package/dist/entry-CHIaWcmk.d.mts.map +0 -1
- package/dist/environments-BYv_kHRG.d.cts +0 -10
- package/dist/environments-BYv_kHRG.d.cts.map +0 -1
- package/dist/environments-BYv_kHRG.d.mts +0 -10
- package/dist/environments-BYv_kHRG.d.mts.map +0 -1
- package/dist/events-NA1XM2Vz.d.cts +0 -10
- package/dist/events-NA1XM2Vz.d.cts.map +0 -1
- package/dist/events-NA1XM2Vz.d.mts +0 -10
- package/dist/events-NA1XM2Vz.d.mts.map +0 -1
- package/dist/extensions-ctxXzgay.d.cts +0 -5
- package/dist/extensions-ctxXzgay.d.cts.map +0 -1
- package/dist/extensions-ctxXzgay.d.mts +0 -5
- package/dist/extensions-ctxXzgay.d.mts.map +0 -1
- package/dist/file-header-Co9oo7aI.d.cts +0 -41
- package/dist/file-header-Co9oo7aI.d.cts.map +0 -1
- package/dist/file-header-rHqeXgRV.d.mts +0 -41
- package/dist/file-header-rHqeXgRV.d.mts.map +0 -1
- package/dist/format-Cf-cgZ-s.d.cts +0 -24
- package/dist/format-Cf-cgZ-s.d.cts.map +0 -1
- package/dist/format-IQPqgWIe.d.mts +0 -24
- package/dist/format-IQPqgWIe.d.mts.map +0 -1
- package/dist/fs-BzXT5ZPj.d.cts +0 -7
- package/dist/fs-BzXT5ZPj.d.cts.map +0 -1
- package/dist/fs-BzXT5ZPj.d.mts +0 -7
- package/dist/fs-BzXT5ZPj.d.mts.map +0 -1
- package/dist/fs-DqLn15uU.mjs.map +0 -1
- package/dist/generate-types-CDkVosrS.d.cts +0 -65
- package/dist/generate-types-CDkVosrS.d.cts.map +0 -1
- package/dist/generate-types-Dw6p3cB_.d.mts +0 -65
- package/dist/generate-types-Dw6p3cB_.d.mts.map +0 -1
- package/dist/helpers-CrRRFQl5.d.mts +0 -22
- package/dist/helpers-CrRRFQl5.d.mts.map +0 -1
- package/dist/helpers-DBLIQW3U.d.cts +0 -22
- package/dist/helpers-DBLIQW3U.d.cts.map +0 -1
- package/dist/hooks-Dhc3ahex.d.cts +0 -5
- package/dist/hooks-Dhc3ahex.d.cts.map +0 -1
- package/dist/hooks-Dhc3ahex.d.mts +0 -5
- package/dist/hooks-Dhc3ahex.d.mts.map +0 -1
- package/dist/index-BKZ67WMa.d.cts +0 -1
- package/dist/index-BKZ67WMa.d.mts +0 -1
- package/dist/index-BVVgDSdq.d.cts +0 -1
- package/dist/index-BVVgDSdq.d.mts +0 -1
- package/dist/index-Den-MsLx.d.cts +0 -1
- package/dist/index-Den-MsLx.d.mts +0 -1
- package/dist/index-DmtQKWjk.d.cts +0 -1
- package/dist/index-DmtQKWjk.d.mts +0 -1
- package/dist/index-LtpXjuJR.d.mts +0 -25
- package/dist/index-LtpXjuJR.d.mts.map +0 -1
- package/dist/index-_6s0AX1B.d.cts +0 -1
- package/dist/index-_6s0AX1B.d.mts +0 -1
- package/dist/index-xk4vSgtB.d.cts +0 -25
- package/dist/index-xk4vSgtB.d.cts.map +0 -1
- package/dist/install-dependencies-CCjZfS9Y.d.mts +0 -12
- package/dist/install-dependencies-CCjZfS9Y.d.mts.map +0 -1
- package/dist/install-dependencies-CyeYsrfz.d.cts +0 -12
- package/dist/install-dependencies-CyeYsrfz.d.cts.map +0 -1
- package/dist/log-level-BC8g4BBL.d.cts +0 -67
- package/dist/log-level-BC8g4BBL.d.cts.map +0 -1
- package/dist/log-level-BC8g4BBL.d.mts +0 -67
- package/dist/log-level-BC8g4BBL.d.mts.map +0 -1
- package/dist/meta-CdDd2ykC.d.cts +0 -33
- package/dist/meta-CdDd2ykC.d.cts.map +0 -1
- package/dist/meta-CfTCHU_o.d.mts +0 -33
- package/dist/meta-CfTCHU_o.d.mts.map +0 -1
- package/dist/meta-QA_SN1j3.d.cts +0 -6
- package/dist/meta-QA_SN1j3.d.cts.map +0 -1
- package/dist/meta-QA_SN1j3.d.mts +0 -6
- package/dist/meta-QA_SN1j3.d.mts.map +0 -1
- package/dist/module-resolution-CRMNPsdn.d.mts +0 -40
- package/dist/module-resolution-CRMNPsdn.d.mts.map +0 -1
- package/dist/module-resolution-D-w-EZaK.d.cts +0 -40
- package/dist/module-resolution-D-w-EZaK.d.cts.map +0 -1
- package/dist/plugin-B_b7XqaN.d.mts +0 -39
- package/dist/plugin-B_b7XqaN.d.mts.map +0 -1
- package/dist/plugin-CzV-aFwU.d.cts +0 -39
- package/dist/plugin-CzV-aFwU.d.cts.map +0 -1
- package/dist/plugin-fhBG7SSQ.d.cts +0 -9
- package/dist/plugin-fhBG7SSQ.d.cts.map +0 -1
- package/dist/plugin-fhBG7SSQ.d.mts +0 -9
- package/dist/plugin-fhBG7SSQ.d.mts.map +0 -1
- package/dist/plugins-DfL1fBZi.d.cts +0 -37
- package/dist/plugins-DfL1fBZi.d.cts.map +0 -1
- package/dist/plugins-zG2X2LA8.d.mts +0 -37
- package/dist/plugins-zG2X2LA8.d.mts.map +0 -1
- package/dist/resolver-CdBAh8dA.d.mts +0 -19
- package/dist/resolver-CdBAh8dA.d.mts.map +0 -1
- package/dist/resolver-CfCl--Eh.d.cts +0 -19
- package/dist/resolver-CfCl--Eh.d.cts.map +0 -1
- package/dist/schemas-Zvqwdrw_.d.cts.map +0 -1
- package/dist/schemas-Zvqwdrw_.d.mts.map +0 -1
- package/dist/source-file-CLw13fKE.d.mts +0 -30
- package/dist/source-file-CLw13fKE.d.mts.map +0 -1
- package/dist/source-file-CuuHaBL5.d.cts +0 -30
- package/dist/source-file-CuuHaBL5.d.cts.map +0 -1
- package/dist/source-map-Cy0aqSpe.d.mts +0 -16
- package/dist/source-map-Cy0aqSpe.d.mts.map +0 -1
- package/dist/source-map-HU4IoICc.d.cts +0 -16
- package/dist/source-map-HU4IoICc.d.cts.map +0 -1
- package/dist/streaming-channel-CiyFd_6l.d.cts +0 -126
- package/dist/streaming-channel-CiyFd_6l.d.cts.map +0 -1
- package/dist/streaming-channel-CiyFd_6l.d.mts +0 -126
- package/dist/streaming-channel-CiyFd_6l.d.mts.map +0 -1
- package/dist/ts-morph-BGgjbOgM.d.cts +0 -38
- package/dist/ts-morph-BGgjbOgM.d.cts.map +0 -1
- package/dist/ts-morph-zLvdifpA.d.mts +0 -38
- package/dist/ts-morph-zLvdifpA.d.mts.map +0 -1
- package/dist/tsconfig-DExoZEQ0.d.cts +0 -75
- package/dist/tsconfig-DExoZEQ0.d.cts.map +0 -1
- package/dist/tsconfig-De09cBeX.d.mts +0 -75
- package/dist/tsconfig-De09cBeX.d.mts.map +0 -1
- package/dist/vfs-B9Vhnajc.d.cts +0 -320
- package/dist/vfs-B9Vhnajc.d.cts.map +0 -1
- package/dist/vfs-Dl6nPqdS.d.mts +0 -320
- package/dist/vfs-Dl6nPqdS.d.mts.map +0 -1
- package/dist/write-file-BVMnXVPo.d.cts +0 -15
- package/dist/write-file-BVMnXVPo.d.cts.map +0 -1
- package/dist/write-file-CWf9Xxwd.d.mts +0 -15
- package/dist/write-file-CWf9Xxwd.d.mts.map +0 -1
package/dist/lib/index.d.mts
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
1
|
+
import { PartiallyResolvedContext, ResolvePackageConfigsResult, defineConfig, getDefaultLogLevel, getDefaultMode, loadParsedConfig, loadUserConfigFile, loadWorkspaceConfig, normalizeBasePath, resolvePackageConfigs, resolveRoot, tryResolveWorkspaceConfig } from "./config.mjs";
|
|
2
|
+
import { getConfigProps, resolvePluginConfig } from "./context-helpers.mjs";
|
|
3
|
+
import { getUniqueInputs, isFileReference, isResolvedEntryFileReference, resolveEntryOutput, resolveInput, resolveInputs, resolveInputsSync } from "./entry.mjs";
|
|
4
|
+
import { createEventEmitter } from "./events.mjs";
|
|
5
|
+
import { TypegenContext, emitBuiltinTypes, formatTypes, handleTypes } from "./generate-types.mjs";
|
|
6
|
+
import { callHook, extractHooks, mergeConfigs, mergeResults } from "./hooks.mjs";
|
|
7
|
+
import { installDependencies } from "./install-dependencies.mjs";
|
|
8
|
+
import { CreateContextOptions, getPersistedMeta, getPrefixedRootHash, writeMetaFile } from "./meta.mjs";
|
|
9
|
+
import { ResolvePluginsOptions, initPlugin, resolvePlugin, resolvePlugins } from "./plugins.mjs";
|
|
10
|
+
import { CreateResolverOptions, createResolver } from "./resolver.mjs";
|
|
11
|
+
import { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, _capnpFileId } from "../schemas/fs.mjs";
|
|
12
|
+
import { BufferedChunk, CreateStreamReaderOptions, CreateStreamSinkOptions, StreamErrorPayload, StreamReader, StreamSink, StreamSinkEvents, createStreamReader, createStreamSink } from "./streaming-channel.mjs";
|
|
13
|
+
import { VirtualFileSystemHost, createProgram } from "./typescript/ts-morph.mjs";
|
|
14
|
+
import { findIncludeMatch, findMatch, getParsedTypeScriptConfig, getTsconfigDtsPath, getTsconfigFilePath, initializeTsconfig, isIncludeMatchFound, isMatchFound, resolveTsconfig, tryTsconfigFilePath } from "./typescript/tsconfig.mjs";
|
|
15
|
+
import { combineContexts, isUnpluginBuilderVariant } from "./unplugin/helpers.mjs";
|
|
16
|
+
import { CreateUnpluginModuleResolutionFunctionsOptions, createUnpluginModuleResolutionFunctions } from "./unplugin/module-resolution.mjs";
|
|
17
|
+
import { CreateUnpluginOptions, CreateUnpluginResolverOptions, createUnplugin, createUnpluginResolver } from "./unplugin/plugin.mjs";
|
|
18
|
+
import { FileHeaderOptions, getFileHeader, getFileHeaderWarning, getFileHeaderWarningText, getTypescriptFileHeader } from "./utilities/file-header.mjs";
|
|
19
|
+
import { format, formatFolder } from "./utilities/format.mjs";
|
|
20
|
+
import { getMagicString, getSourceFile, getString } from "./utilities/source-file.mjs";
|
|
21
|
+
import { generateSourceMap } from "./utilities/source-map.mjs";
|
|
22
|
+
import { writeFile } from "./utilities/write-file.mjs";
|
|
23
|
+
import { VirtualFileSystem } from "./vfs.mjs";
|
|
24
24
|
export { BufferedChunk, CreateContextOptions, CreateResolverOptions, CreateStreamReaderOptions, CreateStreamSinkOptions, CreateUnpluginModuleResolutionFunctionsOptions, CreateUnpluginOptions, CreateUnpluginResolverOptions, FileHeaderOptions, FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, PartiallyResolvedContext, ResolvePackageConfigsResult, ResolvePluginsOptions, StreamErrorPayload, StreamReader, StreamSink, StreamSinkEvents, TypegenContext, VirtualFileSystem, VirtualFileSystemHost, _capnpFileId, callHook, combineContexts, createEventEmitter, createProgram, createResolver, createStreamReader, createStreamSink, createUnplugin, createUnpluginModuleResolutionFunctions, createUnpluginResolver, defineConfig, emitBuiltinTypes, extractHooks, findIncludeMatch, findMatch, format, formatFolder, formatTypes, generateSourceMap, getConfigProps, getDefaultLogLevel, getDefaultMode, getFileHeader, getFileHeaderWarning, getFileHeaderWarningText, getMagicString, getParsedTypeScriptConfig, getPersistedMeta, getPrefixedRootHash, getSourceFile, getString, getTsconfigDtsPath, getTsconfigFilePath, getTypescriptFileHeader, getUniqueInputs, handleTypes, initPlugin, initializeTsconfig, installDependencies, isFileReference, isIncludeMatchFound, isMatchFound, isResolvedEntryFileReference, isUnpluginBuilderVariant, loadParsedConfig, loadUserConfigFile, loadWorkspaceConfig, mergeConfigs, mergeResults, normalizeBasePath, resolveEntryOutput, resolveInput, resolveInputs, resolveInputsSync, resolvePackageConfigs, resolvePlugin, resolvePluginConfig, resolvePlugins, resolveRoot, resolveTsconfig, tryResolveWorkspaceConfig, tryTsconfigFilePath, writeFile, writeMetaFile };
|
package/dist/lib/index.mjs
CHANGED
|
@@ -11,7 +11,7 @@ import { emitBuiltinTypes, formatTypes, handleTypes } from "./generate-types.mjs
|
|
|
11
11
|
import { installDependencies } from "./install-dependencies.mjs";
|
|
12
12
|
import { getPersistedMeta, getPrefixedRootHash, writeMetaFile } from "./meta.mjs";
|
|
13
13
|
import { initPlugin, resolvePlugin, resolvePlugins } from "./plugins.mjs";
|
|
14
|
-
import {
|
|
14
|
+
import { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, _capnpFileId } from "../schemas/fs.mjs";
|
|
15
15
|
import "./schemas.mjs";
|
|
16
16
|
import { createStreamReader, createStreamSink } from "./streaming-channel.mjs";
|
|
17
17
|
import { findIncludeMatch, findMatch, getParsedTypeScriptConfig, getTsconfigDtsPath, getTsconfigFilePath, initializeTsconfig, isIncludeMatchFound, isMatchFound, resolveTsconfig, tryTsconfigFilePath } from "./typescript/tsconfig.mjs";
|
|
@@ -1,2 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { Context } from "../types/context.cjs";
|
|
2
|
+
|
|
3
|
+
//#region src/lib/install-dependencies.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* Install missing project dependencies.
|
|
6
|
+
*
|
|
7
|
+
* @param context - The build context.
|
|
8
|
+
*/
|
|
9
|
+
declare function installDependencies<TContext extends Context = Context>(context: TContext): Promise<void>;
|
|
10
|
+
//#endregion
|
|
11
|
+
export { installDependencies };
|
|
12
|
+
//# sourceMappingURL=install-dependencies.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"install-dependencies.d.cts","names":[],"sources":["../../src/lib/install-dependencies.ts"],"mappings":";;;;;AA2BA;;;iBAAsB,mBAAA,kBAAqC,OAAA,GAAU,OAAA,EACnE,OAAA,EAAS,QAAA,GACR,OAAA"}
|
|
@@ -1,2 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { Context } from "../types/context.mjs";
|
|
2
|
+
|
|
3
|
+
//#region src/lib/install-dependencies.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* Install missing project dependencies.
|
|
6
|
+
*
|
|
7
|
+
* @param context - The build context.
|
|
8
|
+
*/
|
|
9
|
+
declare function installDependencies<TContext extends Context = Context>(context: TContext): Promise<void>;
|
|
10
|
+
//#endregion
|
|
11
|
+
export { installDependencies };
|
|
12
|
+
//# sourceMappingURL=install-dependencies.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"install-dependencies.d.mts","names":[],"sources":["../../src/lib/install-dependencies.ts"],"mappings":";;;;;AA2BA;;;iBAAsB,mBAAA,kBAAqC,OAAA,GAAU,OAAA,EACnE,OAAA,EAAS,QAAA,GACR,OAAA"}
|
package/dist/lib/meta.d.cts
CHANGED
|
@@ -1,2 +1,33 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { Context, MetaInfo } from "../types/context.cjs";
|
|
2
|
+
//#region src/lib/meta.d.ts
|
|
3
|
+
interface CreateContextOptions {
|
|
4
|
+
name?: string;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Generates a prefixed project root hash object.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function returns a string where the project root hash is prefixed with the project name plus a hyphen. If the total length of this string combination exceeds 45 characters, it will truncate the hash.
|
|
11
|
+
*
|
|
12
|
+
* @param name - The name of the project.
|
|
13
|
+
* @param rootHash - The hash of the project root.
|
|
14
|
+
* @returns An object containing the name and project root hash.
|
|
15
|
+
*/
|
|
16
|
+
declare function getPrefixedRootHash(name: string, rootHash: string): string;
|
|
17
|
+
/**
|
|
18
|
+
* Retrieves the persisted meta information from the context's data path.
|
|
19
|
+
*
|
|
20
|
+
* @param context - The build context.
|
|
21
|
+
* @returns A promise that resolves to the persisted meta information, or undefined if not found.
|
|
22
|
+
*/
|
|
23
|
+
declare function getPersistedMeta(context: Context): Promise<MetaInfo | undefined>;
|
|
24
|
+
/**
|
|
25
|
+
* Writes the meta file for the context.
|
|
26
|
+
*
|
|
27
|
+
* @param context - The context to write the meta file for.
|
|
28
|
+
* @returns A promise that resolves when the meta file has been written.
|
|
29
|
+
*/
|
|
30
|
+
declare function writeMetaFile(context: Context): Promise<void>;
|
|
31
|
+
//#endregion
|
|
32
|
+
export { CreateContextOptions, getPersistedMeta, getPrefixedRootHash, writeMetaFile };
|
|
33
|
+
//# sourceMappingURL=meta.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"meta.d.cts","names":[],"sources":["../../src/lib/meta.ts"],"mappings":";;UA0BiB,oBAAA;EACf,IAAI;AAAA;AADN;;;;AACM;AAaN;;;;AAAkE;AAdlE,iBAcgB,mBAAA,CAAoB,IAAA,UAAc,QAAgB;;;;;;;iBAc5C,gBAAA,CACpB,OAAA,EAAS,OAAA,GACR,OAAA,CAAQ,QAAA;;;;;;AAAQ;iBAwBG,aAAA,CAAc,OAAA,EAAS,OAAA,GAAU,OAAO"}
|
package/dist/lib/meta.d.mts
CHANGED
|
@@ -1,2 +1,33 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { Context, MetaInfo } from "../types/context.mjs";
|
|
2
|
+
//#region src/lib/meta.d.ts
|
|
3
|
+
interface CreateContextOptions {
|
|
4
|
+
name?: string;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Generates a prefixed project root hash object.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function returns a string where the project root hash is prefixed with the project name plus a hyphen. If the total length of this string combination exceeds 45 characters, it will truncate the hash.
|
|
11
|
+
*
|
|
12
|
+
* @param name - The name of the project.
|
|
13
|
+
* @param rootHash - The hash of the project root.
|
|
14
|
+
* @returns An object containing the name and project root hash.
|
|
15
|
+
*/
|
|
16
|
+
declare function getPrefixedRootHash(name: string, rootHash: string): string;
|
|
17
|
+
/**
|
|
18
|
+
* Retrieves the persisted meta information from the context's data path.
|
|
19
|
+
*
|
|
20
|
+
* @param context - The build context.
|
|
21
|
+
* @returns A promise that resolves to the persisted meta information, or undefined if not found.
|
|
22
|
+
*/
|
|
23
|
+
declare function getPersistedMeta(context: Context): Promise<MetaInfo | undefined>;
|
|
24
|
+
/**
|
|
25
|
+
* Writes the meta file for the context.
|
|
26
|
+
*
|
|
27
|
+
* @param context - The context to write the meta file for.
|
|
28
|
+
* @returns A promise that resolves when the meta file has been written.
|
|
29
|
+
*/
|
|
30
|
+
declare function writeMetaFile(context: Context): Promise<void>;
|
|
31
|
+
//#endregion
|
|
32
|
+
export { CreateContextOptions, getPersistedMeta, getPrefixedRootHash, writeMetaFile };
|
|
33
|
+
//# sourceMappingURL=meta.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"meta.d.mts","names":[],"sources":["../../src/lib/meta.ts"],"mappings":";;UA0BiB,oBAAA;EACf,IAAI;AAAA;AADN;;;;AACM;AAaN;;;;AAAkE;AAdlE,iBAcgB,mBAAA,CAAoB,IAAA,UAAc,QAAgB;;;;;;;iBAc5C,gBAAA,CACpB,OAAA,EAAS,OAAA,GACR,OAAA,CAAQ,QAAA;;;;;;AAAQ;iBAwBG,aAAA,CAAc,OAAA,EAAS,OAAA,GAAU,OAAO"}
|
package/dist/lib/plugins.cjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
-
const
|
|
2
|
+
const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
|
|
3
3
|
const require_plugin_utils_helpers = require('../plugin-utils/helpers.cjs');
|
|
4
4
|
require('../plugin-utils/index.cjs');
|
|
5
5
|
let _stryke_type_checks_is_function = require("@stryke/type-checks/is-function");
|
|
6
6
|
let _stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-string");
|
|
7
7
|
let _stryke_type_checks_is_string = require("@stryke/type-checks/is-string");
|
|
8
8
|
let chalk = require("chalk");
|
|
9
|
-
chalk =
|
|
9
|
+
chalk = require_runtime.__toESM(chalk, 1);
|
|
10
10
|
let _stryke_convert_to_array = require("@stryke/convert/to-array");
|
|
11
11
|
let _stryke_path_join = require("@stryke/path/join");
|
|
12
12
|
let _stryke_fs_install = require("@stryke/fs/install");
|
package/dist/lib/plugins.d.cts
CHANGED
|
@@ -1,2 +1,39 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { Plugin } from "../types/plugin.cjs";
|
|
2
|
+
import { EnvironmentContext, ExecutionContext, PluginContext } from "../types/context.cjs";
|
|
3
|
+
import { PluginConfig, ResolvedConfig } from "../types/config.cjs";
|
|
4
|
+
import { MaybePromise } from "@stryke/types/base";
|
|
5
|
+
|
|
6
|
+
//#region src/lib/plugins.d.ts
|
|
7
|
+
/**
|
|
8
|
+
* Resolve a plugin module based on the provided plugin path. This function checks if the plugin package is installed, attempts to import the plugin module, and handles various error cases such as missing packages or invalid module exports. It supports both direct plugin exports and plugins exported from a "plugin" subdirectory within the package.
|
|
9
|
+
*
|
|
10
|
+
* @param context - The execution context in which the plugin will be initialized. This context provides access to configuration, logging, and other utilities that may be needed during plugin initialization.
|
|
11
|
+
* @param pluginPath - The path to the plugin module. This can be a package name, a scoped package name, or a path to a local module.
|
|
12
|
+
* @returns A promise that resolves to the plugin module, which can be a plugin instance, a factory function that returns a plugin, or an array of plugins.
|
|
13
|
+
*/
|
|
14
|
+
declare function resolvePlugin<TResolvedConfig extends ResolvedConfig, TSystemContext, TContext extends EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext> = EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext>, TPluginContext extends PluginContext<TResolvedConfig, TSystemContext> = PluginContext<TResolvedConfig, TSystemContext>>(context: TContext, pluginPath: string): Promise<Plugin<TPluginContext> | Plugin<TPluginContext>[] | ((options?: any) => MaybePromise<Plugin<TPluginContext> | Plugin<TPluginContext>[]>)>;
|
|
15
|
+
/**
|
|
16
|
+
* Initialize a plugin based on the provided plugin configuration. This function handles various forms of plugin configurations, including direct plugin instances, factory functions, string paths to plugins, and arrays of plugins or plugin configurations. It validates the plugin configuration, resolves any plugin paths, and returns an array of initialized plugins.
|
|
17
|
+
*
|
|
18
|
+
* @param context - The execution context in which the plugin will be initialized. This context provides access to configuration, logging, and other utilities that may be needed during plugin initialization.
|
|
19
|
+
* @param config - The plugin configuration, which can be in various forms such as a direct plugin instance, a string path to a plugin, a factory function that returns a plugin, or an array of plugins or plugin configurations. This configuration will be processed and validated to initialize the appropriate plugins.
|
|
20
|
+
* @returns A promise that resolves to an array of initialized plugins based on the provided configuration. If the configuration is invalid, an error will be thrown with details about the issue.
|
|
21
|
+
*/
|
|
22
|
+
declare function initPlugin<TResolvedConfig extends ResolvedConfig, TSystemContext, TContext extends EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext> = EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext>, TPluginContext extends PluginContext<TResolvedConfig, TSystemContext> = PluginContext<TResolvedConfig, TSystemContext>>(context: TContext, config: PluginConfig<TPluginContext>, options?: ResolvePluginsOptions): Promise<Plugin<TPluginContext>[] | null>;
|
|
23
|
+
interface ResolvePluginsOptions {
|
|
24
|
+
/**
|
|
25
|
+
* If true, the plugin resolution process will skip logging messages about the plugin initialization. This can be useful in scenarios where you want to suppress plugin-related logs, such as when running in a non-interactive environment or when you want to reduce log verbosity. By default, this option is false, and plugin initialization messages will be logged using the context's logger.
|
|
26
|
+
*/
|
|
27
|
+
skipLogging?: boolean;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Initialize a plugin based on the provided plugin configuration. This function handles various forms of plugin configurations, including direct plugin instances, plugin names, factory functions, and arrays of plugins. It validates the configuration, resolves plugin modules if necessary, and returns an array of initialized plugins ready to be added to the execution context.
|
|
31
|
+
*
|
|
32
|
+
* @param context - The execution context in which the plugin will be initialized. This context provides access to configuration, logging, and other utilities that may be needed during plugin initialization.
|
|
33
|
+
* @param config - The plugin configuration, which can be in various forms such as a plugin instance, a plugin name string, a factory function that returns a plugin or an array of plugins, or an array of plugin configurations. The function will handle the resolution and initialization of the plugin(s) based on the provided configuration.
|
|
34
|
+
* @returns A promise that resolves to an array of initialized plugins that can be added to the execution context, or null if the configuration is invalid or results in no plugins being initialized.
|
|
35
|
+
*/
|
|
36
|
+
declare function resolvePlugins<TResolvedConfig extends ResolvedConfig, TSystemContext, TContext extends EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext> = EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext>, TPluginContext extends PluginContext<TResolvedConfig, TSystemContext> = PluginContext<TResolvedConfig, TSystemContext>>(context: TContext, config: PluginConfig<TPluginContext>, options?: ResolvePluginsOptions): Promise<Plugin<TPluginContext>[]>;
|
|
37
|
+
//#endregion
|
|
38
|
+
export { ResolvePluginsOptions, initPlugin, resolvePlugin, resolvePlugins };
|
|
39
|
+
//# sourceMappingURL=plugins.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugins.d.cts","names":[],"sources":["../../src/lib/plugins.ts"],"mappings":";;;;;;;;;;;AAwDA;;iBAAsB,aAAA,yBACI,cAAA,mCAGpB,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAClC,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,0BACf,aAAA,CAAc,eAAA,EAAiB,cAAA,IACpD,aAAA,CAAc,eAAA,EAAiB,cAAA,GAEjC,OAAA,EAAS,QAAA,EACT,UAAA,WACC,OAAA,CACC,MAAA,CAAO,cAAA,IACP,MAAA,CAAO,cAAA,QAEL,OAAA,WACG,YAAA,CAAa,MAAA,CAAO,cAAA,IAAkB,MAAA,CAAO,cAAA;;;;;;;;iBAsGhC,UAAA,yBACI,cAAA,mCAGpB,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAClC,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,0BACf,aAAA,CAAc,eAAA,EAAiB,cAAA,IACpD,aAAA,CAAc,eAAA,EAAiB,cAAA,GAEjC,OAAA,EAAS,QAAA,EACT,MAAA,EAAQ,YAAA,CAAa,cAAA,GACrB,OAAA,GAAS,qBAAA,GACR,OAAA,CAAQ,MAAA,CAAO,cAAA;AAAA,UAwJD,qBAAA;EAxRX;;;EA4RJ,WAAW;AAAA;;;;;;;;iBAUS,cAAA,yBACI,cAAA,mCAGpB,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAClC,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,0BACf,aAAA,CAAc,eAAA,EAAiB,cAAA,IACpD,aAAA,CAAc,eAAA,EAAiB,cAAA,GAEjC,OAAA,EAAS,QAAA,EACT,MAAA,EAAQ,YAAA,CAAa,cAAA,GACrB,OAAA,GAAS,qBAAA,GAA0B,OAAA,CAAA,MAAA,CAAA,cAAA"}
|
package/dist/lib/plugins.d.mts
CHANGED
|
@@ -1,2 +1,39 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { Plugin } from "../types/plugin.mjs";
|
|
2
|
+
import { EnvironmentContext, ExecutionContext, PluginContext } from "../types/context.mjs";
|
|
3
|
+
import { PluginConfig, ResolvedConfig } from "../types/config.mjs";
|
|
4
|
+
import { MaybePromise } from "@stryke/types/base";
|
|
5
|
+
|
|
6
|
+
//#region src/lib/plugins.d.ts
|
|
7
|
+
/**
|
|
8
|
+
* Resolve a plugin module based on the provided plugin path. This function checks if the plugin package is installed, attempts to import the plugin module, and handles various error cases such as missing packages or invalid module exports. It supports both direct plugin exports and plugins exported from a "plugin" subdirectory within the package.
|
|
9
|
+
*
|
|
10
|
+
* @param context - The execution context in which the plugin will be initialized. This context provides access to configuration, logging, and other utilities that may be needed during plugin initialization.
|
|
11
|
+
* @param pluginPath - The path to the plugin module. This can be a package name, a scoped package name, or a path to a local module.
|
|
12
|
+
* @returns A promise that resolves to the plugin module, which can be a plugin instance, a factory function that returns a plugin, or an array of plugins.
|
|
13
|
+
*/
|
|
14
|
+
declare function resolvePlugin<TResolvedConfig extends ResolvedConfig, TSystemContext, TContext extends EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext> = EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext>, TPluginContext extends PluginContext<TResolvedConfig, TSystemContext> = PluginContext<TResolvedConfig, TSystemContext>>(context: TContext, pluginPath: string): Promise<Plugin<TPluginContext> | Plugin<TPluginContext>[] | ((options?: any) => MaybePromise<Plugin<TPluginContext> | Plugin<TPluginContext>[]>)>;
|
|
15
|
+
/**
|
|
16
|
+
* Initialize a plugin based on the provided plugin configuration. This function handles various forms of plugin configurations, including direct plugin instances, factory functions, string paths to plugins, and arrays of plugins or plugin configurations. It validates the plugin configuration, resolves any plugin paths, and returns an array of initialized plugins.
|
|
17
|
+
*
|
|
18
|
+
* @param context - The execution context in which the plugin will be initialized. This context provides access to configuration, logging, and other utilities that may be needed during plugin initialization.
|
|
19
|
+
* @param config - The plugin configuration, which can be in various forms such as a direct plugin instance, a string path to a plugin, a factory function that returns a plugin, or an array of plugins or plugin configurations. This configuration will be processed and validated to initialize the appropriate plugins.
|
|
20
|
+
* @returns A promise that resolves to an array of initialized plugins based on the provided configuration. If the configuration is invalid, an error will be thrown with details about the issue.
|
|
21
|
+
*/
|
|
22
|
+
declare function initPlugin<TResolvedConfig extends ResolvedConfig, TSystemContext, TContext extends EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext> = EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext>, TPluginContext extends PluginContext<TResolvedConfig, TSystemContext> = PluginContext<TResolvedConfig, TSystemContext>>(context: TContext, config: PluginConfig<TPluginContext>, options?: ResolvePluginsOptions): Promise<Plugin<TPluginContext>[] | null>;
|
|
23
|
+
interface ResolvePluginsOptions {
|
|
24
|
+
/**
|
|
25
|
+
* If true, the plugin resolution process will skip logging messages about the plugin initialization. This can be useful in scenarios where you want to suppress plugin-related logs, such as when running in a non-interactive environment or when you want to reduce log verbosity. By default, this option is false, and plugin initialization messages will be logged using the context's logger.
|
|
26
|
+
*/
|
|
27
|
+
skipLogging?: boolean;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Initialize a plugin based on the provided plugin configuration. This function handles various forms of plugin configurations, including direct plugin instances, plugin names, factory functions, and arrays of plugins. It validates the configuration, resolves plugin modules if necessary, and returns an array of initialized plugins ready to be added to the execution context.
|
|
31
|
+
*
|
|
32
|
+
* @param context - The execution context in which the plugin will be initialized. This context provides access to configuration, logging, and other utilities that may be needed during plugin initialization.
|
|
33
|
+
* @param config - The plugin configuration, which can be in various forms such as a plugin instance, a plugin name string, a factory function that returns a plugin or an array of plugins, or an array of plugin configurations. The function will handle the resolution and initialization of the plugin(s) based on the provided configuration.
|
|
34
|
+
* @returns A promise that resolves to an array of initialized plugins that can be added to the execution context, or null if the configuration is invalid or results in no plugins being initialized.
|
|
35
|
+
*/
|
|
36
|
+
declare function resolvePlugins<TResolvedConfig extends ResolvedConfig, TSystemContext, TContext extends EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext> = EnvironmentContext<TResolvedConfig, TSystemContext> | ExecutionContext<TResolvedConfig, TSystemContext>, TPluginContext extends PluginContext<TResolvedConfig, TSystemContext> = PluginContext<TResolvedConfig, TSystemContext>>(context: TContext, config: PluginConfig<TPluginContext>, options?: ResolvePluginsOptions): Promise<Plugin<TPluginContext>[]>;
|
|
37
|
+
//#endregion
|
|
38
|
+
export { ResolvePluginsOptions, initPlugin, resolvePlugin, resolvePlugins };
|
|
39
|
+
//# sourceMappingURL=plugins.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugins.d.mts","names":[],"sources":["../../src/lib/plugins.ts"],"mappings":";;;;;;;;;;;AAwDA;;iBAAsB,aAAA,yBACI,cAAA,mCAGpB,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAClC,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,0BACf,aAAA,CAAc,eAAA,EAAiB,cAAA,IACpD,aAAA,CAAc,eAAA,EAAiB,cAAA,GAEjC,OAAA,EAAS,QAAA,EACT,UAAA,WACC,OAAA,CACC,MAAA,CAAO,cAAA,IACP,MAAA,CAAO,cAAA,QAEL,OAAA,WACG,YAAA,CAAa,MAAA,CAAO,cAAA,IAAkB,MAAA,CAAO,cAAA;;;;;;;;iBAsGhC,UAAA,yBACI,cAAA,mCAGpB,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAClC,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,0BACf,aAAA,CAAc,eAAA,EAAiB,cAAA,IACpD,aAAA,CAAc,eAAA,EAAiB,cAAA,GAEjC,OAAA,EAAS,QAAA,EACT,MAAA,EAAQ,YAAA,CAAa,cAAA,GACrB,OAAA,GAAS,qBAAA,GACR,OAAA,CAAQ,MAAA,CAAO,cAAA;AAAA,UAwJD,qBAAA;EAxRX;;;EA4RJ,WAAW;AAAA;;;;;;;;iBAUS,cAAA,yBACI,cAAA,mCAGpB,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAClC,kBAAA,CAAmB,eAAA,EAAiB,cAAA,IACpC,gBAAA,CAAiB,eAAA,EAAiB,cAAA,0BACf,aAAA,CAAc,eAAA,EAAiB,cAAA,IACpD,aAAA,CAAc,eAAA,EAAiB,cAAA,GAEjC,OAAA,EAAS,QAAA,EACT,MAAA,EAAQ,YAAA,CAAa,cAAA,GACrB,OAAA,GAAS,qBAAA,GAA0B,OAAA,CAAA,MAAA,CAAA,cAAA"}
|
package/dist/lib/resolver.cjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
-
const
|
|
2
|
+
const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
|
|
3
3
|
let _stryke_path_join_paths = require("@stryke/path/join-paths");
|
|
4
4
|
let defu = require("defu");
|
|
5
|
-
defu =
|
|
5
|
+
defu = require_runtime.__toESM(defu, 1);
|
|
6
6
|
let jiti = require("jiti");
|
|
7
7
|
|
|
8
8
|
//#region src/lib/resolver.ts
|
package/dist/lib/resolver.d.cts
CHANGED
|
@@ -1,2 +1,20 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { Resolver } from "../types/context.cjs";
|
|
2
|
+
import { ResolvedConfig } from "../types/config.cjs";
|
|
3
|
+
import { JitiOptions } from "jiti";
|
|
4
|
+
|
|
5
|
+
//#region src/lib/resolver.d.ts
|
|
6
|
+
type CreateResolverOptions = Omit<JitiOptions, "fsCache" | "moduleCache" | "interopDefault"> & Partial<Pick<ResolvedConfig, "mode" | "skipCache">> & {
|
|
7
|
+
cwd: string;
|
|
8
|
+
root: string;
|
|
9
|
+
cacheDir: string;
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* Create a Jiti resolver for the given workspace and project root.
|
|
13
|
+
*
|
|
14
|
+
* @param options - The options for creating the resolver.
|
|
15
|
+
* @returns A Jiti instance configured for the specified workspace and project root.
|
|
16
|
+
*/
|
|
17
|
+
declare function createResolver(options: CreateResolverOptions): Resolver;
|
|
18
|
+
//#endregion
|
|
19
|
+
export { CreateResolverOptions, createResolver };
|
|
20
|
+
//# sourceMappingURL=resolver.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resolver.d.cts","names":[],"sources":["../../src/lib/resolver.ts"],"mappings":";;;;;KAwBY,qBAAA,GAAwB,IAAA,CAClC,WAAA,kDAGA,OAAA,CAAQ,IAAA,CAAK,cAAA;EACX,GAAA;EACA,IAAA;EACA,QAAA;AAAA;;;;;;;iBA0BY,cAAA,CAAe,OAAA,EAAS,qBAAA,GAAwB,QAAQ"}
|
package/dist/lib/resolver.d.mts
CHANGED
|
@@ -1,2 +1,20 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { Resolver } from "../types/context.mjs";
|
|
2
|
+
import { ResolvedConfig } from "../types/config.mjs";
|
|
3
|
+
import { JitiOptions } from "jiti";
|
|
4
|
+
|
|
5
|
+
//#region src/lib/resolver.d.ts
|
|
6
|
+
type CreateResolverOptions = Omit<JitiOptions, "fsCache" | "moduleCache" | "interopDefault"> & Partial<Pick<ResolvedConfig, "mode" | "skipCache">> & {
|
|
7
|
+
cwd: string;
|
|
8
|
+
root: string;
|
|
9
|
+
cacheDir: string;
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* Create a Jiti resolver for the given workspace and project root.
|
|
13
|
+
*
|
|
14
|
+
* @param options - The options for creating the resolver.
|
|
15
|
+
* @returns A Jiti instance configured for the specified workspace and project root.
|
|
16
|
+
*/
|
|
17
|
+
declare function createResolver(options: CreateResolverOptions): Resolver;
|
|
18
|
+
//#endregion
|
|
19
|
+
export { CreateResolverOptions, createResolver };
|
|
20
|
+
//# sourceMappingURL=resolver.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resolver.d.mts","names":[],"sources":["../../src/lib/resolver.ts"],"mappings":";;;;;KAwBY,qBAAA,GAAwB,IAAA,CAClC,WAAA,kDAGA,OAAA,CAAQ,IAAA,CAAK,cAAA;EACX,GAAA;EACA,IAAA;EACA,QAAA;AAAA;;;;;;;iBA0BY,cAAA,CAAe,OAAA,EAAS,qBAAA,GAAwB,QAAQ"}
|
package/dist/lib/schemas.cjs
CHANGED
package/dist/lib/schemas.d.cts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, _capnpFileId } from "../schemas/fs.cjs";
|
|
2
2
|
export { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, _capnpFileId };
|
package/dist/lib/schemas.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, _capnpFileId } from "../schemas/fs.mjs";
|
|
2
2
|
export { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, _capnpFileId };
|
package/dist/lib/schemas.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, _capnpFileId } from "../schemas/fs.mjs";
|
|
2
2
|
|
|
3
3
|
export { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, _capnpFileId };
|
|
@@ -1,2 +1,126 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { EventEmitter } from "devframe/types";
|
|
2
|
+
|
|
3
|
+
//#region src/lib/streaming-channel.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* Serialized error shape sent over the wire when a stream ends with a failure.
|
|
6
|
+
* Stays JSON-safe so the strict-JSON encoder can carry it without coercion.
|
|
7
|
+
*/
|
|
8
|
+
interface StreamErrorPayload {
|
|
9
|
+
name: string;
|
|
10
|
+
message: string;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Single buffered chunk in the server-side ring buffer.
|
|
14
|
+
*
|
|
15
|
+
* Sequence numbers start at 1 and increment per write. Subscribers track
|
|
16
|
+
* `lastSeenSeq` and ask for `afterSeq` on resubscribe so the server can
|
|
17
|
+
* replay any chunks the client missed during a brief disconnect.
|
|
18
|
+
*/
|
|
19
|
+
interface BufferedChunk<T> {
|
|
20
|
+
seq: number;
|
|
21
|
+
chunk: T;
|
|
22
|
+
}
|
|
23
|
+
interface StreamSinkEvents<T> {
|
|
24
|
+
/** Fired for each `write()`. The RPC layer subscribes and broadcasts. */
|
|
25
|
+
chunk: (seq: number, chunk: T) => void;
|
|
26
|
+
/** Terminal — fired exactly once per sink lifetime. */
|
|
27
|
+
end: (error?: StreamErrorPayload) => void;
|
|
28
|
+
}
|
|
29
|
+
interface CreateStreamSinkOptions {
|
|
30
|
+
id?: string;
|
|
31
|
+
/**
|
|
32
|
+
* Size of the per-stream ring buffer kept for replay-on-resubscribe.
|
|
33
|
+
* `0` (default) disables replay.
|
|
34
|
+
*/
|
|
35
|
+
replayWindow?: number;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Server-side producer handle. Two equivalent surfaces share one piece of
|
|
39
|
+
* state: the imperative `write/error/close` triple, and a `WritableStream<T>`
|
|
40
|
+
* for `pipeTo`-style consumption.
|
|
41
|
+
*/
|
|
42
|
+
interface StreamSink<T> {
|
|
43
|
+
/** Stable id used by clients to subscribe. */
|
|
44
|
+
readonly id: string;
|
|
45
|
+
/**
|
|
46
|
+
* Aborts when the consumer cancels (server-side) or when the transport
|
|
47
|
+
* loses every subscriber. Producers should poll `signal.aborted` and exit
|
|
48
|
+
* cleanly.
|
|
49
|
+
*/
|
|
50
|
+
readonly signal: AbortSignal;
|
|
51
|
+
/** `true` after `close()` / `error()`. Further writes throw. */
|
|
52
|
+
readonly closed: boolean;
|
|
53
|
+
/** Last allocated sequence number. `0` until the first write. */
|
|
54
|
+
readonly lastSeq: number;
|
|
55
|
+
write: (chunk: T) => void;
|
|
56
|
+
error: (reason: unknown) => void;
|
|
57
|
+
close: () => void;
|
|
58
|
+
/** External-cancel path. Aborts the signal so handlers can short-circuit. */
|
|
59
|
+
abort: (reason?: unknown) => void;
|
|
60
|
+
/** `WritableStream<T>` adapter — same in-memory state as the imperative API. */
|
|
61
|
+
readonly writable: WritableStream<T>;
|
|
62
|
+
/**
|
|
63
|
+
* Internal — RPC layer subscribes to receive chunk/end notifications.
|
|
64
|
+
* Not part of the public contract; do not call directly.
|
|
65
|
+
*
|
|
66
|
+
* @internal
|
|
67
|
+
*/
|
|
68
|
+
readonly events: EventEmitter<StreamSinkEvents<T>>;
|
|
69
|
+
/**
|
|
70
|
+
* Internal — replay buffer. RPC layer reads on (re)subscribe to feed
|
|
71
|
+
* missed chunks before going live.
|
|
72
|
+
*
|
|
73
|
+
* @internal
|
|
74
|
+
*/
|
|
75
|
+
readonly buffer: ReadonlyArray<BufferedChunk<T>>;
|
|
76
|
+
}
|
|
77
|
+
interface CreateStreamReaderOptions {
|
|
78
|
+
id?: string;
|
|
79
|
+
/**
|
|
80
|
+
* Maximum number of buffered chunks held client-side while the consumer
|
|
81
|
+
* isn't draining. On overflow, the oldest chunk is dropped.
|
|
82
|
+
*/
|
|
83
|
+
highWaterMark?: number;
|
|
84
|
+
/**
|
|
85
|
+
* Called when the chunk queue overflows the high-water mark. The RPC
|
|
86
|
+
* layer wires this to a coded warning; the primitive itself is
|
|
87
|
+
* RPC-agnostic.
|
|
88
|
+
*/
|
|
89
|
+
onOverflow?: (dropped: number) => void;
|
|
90
|
+
/** Called when the consumer cancels — the RPC layer sends `:cancel` upstream. */
|
|
91
|
+
onCancel?: () => void;
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Client-side consumer handle. Both an `AsyncIterable<T>` (for `for await`)
|
|
95
|
+
* and exposes `readable: ReadableStream<T>` (for `pipeTo`). Pick one — they
|
|
96
|
+
* share a single internal queue, so concurrent draining will race.
|
|
97
|
+
*/
|
|
98
|
+
interface StreamReader<T> extends AsyncIterable<T> {
|
|
99
|
+
readonly id: string;
|
|
100
|
+
readonly cancelled: boolean;
|
|
101
|
+
readonly done: boolean;
|
|
102
|
+
/** Highest `seq` observed. Used for replay on reconnect. */
|
|
103
|
+
readonly lastSeenSeq: number;
|
|
104
|
+
/** `ReadableStream<T>` adapter for `pipeTo`-style consumption. */
|
|
105
|
+
readonly readable: ReadableStream<T>;
|
|
106
|
+
cancel: () => void;
|
|
107
|
+
/** @internal */
|
|
108
|
+
_push: (seq: number, chunk: T) => void;
|
|
109
|
+
/** @internal */
|
|
110
|
+
_end: (error?: StreamErrorPayload) => void;
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Build a server-side stream sink. RPC-agnostic — the RPC host wires
|
|
114
|
+
* `events.on('chunk' | 'end')` to broadcast, and reads `buffer` to replay
|
|
115
|
+
* for late or reconnecting subscribers.
|
|
116
|
+
*/
|
|
117
|
+
declare function createStreamSink<T>(options?: CreateStreamSinkOptions): StreamSink<T>;
|
|
118
|
+
/**
|
|
119
|
+
* Build a client-side stream reader. RPC-agnostic — the RPC host calls
|
|
120
|
+
* `_push(seq, chunk)` on each incoming chunk and `_end(error?)` on the
|
|
121
|
+
* terminal frame. Consumers iterate with `for await` or pipe `readable`.
|
|
122
|
+
*/
|
|
123
|
+
declare function createStreamReader<T>(options?: CreateStreamReaderOptions): StreamReader<T>;
|
|
124
|
+
//#endregion
|
|
125
|
+
export { BufferedChunk, CreateStreamReaderOptions, CreateStreamSinkOptions, StreamErrorPayload, StreamReader, StreamSink, StreamSinkEvents, createStreamReader, createStreamSink };
|
|
126
|
+
//# sourceMappingURL=streaming-channel.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"streaming-channel.d.cts","names":[],"sources":["../../src/lib/streaming-channel.ts"],"mappings":";;;;;AA0BA;;UAAiB,kBAAA;EACf,IAAA;EACA,OAAO;AAAA;;;;;;;;UAUQ,aAAA;EACf,GAAA;EACA,KAAA,EAAO,CAAC;AAAA;AAAA,UAGO,gBAAA;EAIiB;EAFhC,KAAA,GAAQ,GAAA,UAAa,KAAA,EAAO,CAAA;EAA5B;EAEA,GAAA,GAAM,KAAA,GAAQ,kBAAkB;AAAA;AAAA,UAGjB,uBAAA;EACf,EAAA;EAJc;;;AAAkB;EAShC,YAAY;AAAA;;;AAAA;AAQd;;UAAiB,UAAA;EAQE;EAAA,SANR,EAAA;EAmByB;;;;;EAAA,SAbzB,MAAA,EAAQ,WAAA;EA6Bc;EAAA,SA3BtB,MAAA;EA2BqB;EAAA,SAzBrB,OAAA;EAET,KAAA,GAAQ,KAAA,EAAO,CAAA;EACf,KAAA,GAAQ,MAAA;EACR,KAAA;EARiB;EAUjB,KAAA,GAAQ,MAAA;EANC;EAAA,SASA,QAAA,EAAU,cAAA,CAAe,CAAA;EAPnB;;;;;;EAAA,SAeN,MAAA,EAAQ,YAAA,CAAa,gBAAA,CAAiB,CAAA;EARtC;;;;;;EAAA,SAgBA,MAAA,EAAQ,aAAA,CAAc,aAAA,CAAc,CAAA;AAAA;AAAA,UAG9B,yBAAA;EACf,EAAA;EAJ6C;;AAAC;AAGhD;EAME,aAAA;;;;;;EAMA,UAAA,IAAc,OAAA;EAEd;EAAA,QAAA;AAAA;AAQF;;;;;AAAA,UAAiB,YAAA,YAAwB,aAAA,CAAc,CAAA;EAAA,SAC5C,EAAA;EAAA,SACA,SAAA;EAAA,SACA,IAAA;EAH2C;EAAA,SAK3C,WAAA;EALmB;EAAA,SAOnB,QAAA,EAAU,cAAA,CAAe,CAAA;EAElC,MAAA;EARS;EAWT,KAAA,GAAQ,GAAA,UAAa,KAAA,EAAO,CAAA;EATnB;EAWT,IAAA,GAAO,KAAA,GAAQ,kBAAA;AAAA;;;;;;iBAcD,gBAAA,IACd,OAAA,GAAS,uBAAA,GACR,UAAA,CAAW,CAAA;;;;;;iBA+EE,kBAAA,IACd,OAAA,GAAS,yBAAA,GACR,YAAA,CAAa,CAAA"}
|