@skillcap/gdh 3.2.1 → 3.2.3
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/INSTALL-BUNDLE.json +1 -1
- package/RELEASE-SPAN-UPDATE-CONTRACTS.json +134 -0
- package/node_modules/@clack/core/CHANGELOG.md +8 -0
- package/node_modules/@clack/core/dist/index.d.mts +18 -4
- package/node_modules/@clack/core/dist/index.mjs +16 -10
- package/node_modules/@clack/core/dist/index.mjs.map +1 -1
- package/node_modules/@clack/core/package.json +5 -2
- package/node_modules/@clack/prompts/CHANGELOG.md +15 -0
- package/node_modules/@clack/prompts/README.md +107 -2
- package/node_modules/@clack/prompts/dist/index.d.mts +16 -11
- package/node_modules/@clack/prompts/dist/index.mjs +114 -107
- package/node_modules/@clack/prompts/dist/index.mjs.map +1 -1
- package/node_modules/@clack/prompts/package.json +7 -4
- package/node_modules/@gdh/adapters/dist/authoring-hook-render.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/authoring-hook-render.js +1 -1
- package/node_modules/@gdh/adapters/dist/authoring-hook-render.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/claude-settings-patch.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/claude-settings-patch.js +4 -2
- package/node_modules/@gdh/adapters/dist/claude-settings-patch.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/claude-statusline-render.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/claude-statusline-render.js +1 -1
- package/node_modules/@gdh/adapters/dist/claude-statusline-render.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/claude-update-hook-render.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/claude-update-hook-render.js +1 -1
- package/node_modules/@gdh/adapters/dist/claude-update-hook-render.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/claude-update-worker-render.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/claude-update-worker-render.js +1 -1
- package/node_modules/@gdh/adapters/dist/claude-update-worker-render.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/deferred-actions-advisory.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/deferred-actions-advisory.js +1 -1
- package/node_modules/@gdh/adapters/dist/deferred-actions-advisory.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/durable-backup.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/durable-backup.js +3 -5
- package/node_modules/@gdh/adapters/dist/durable-backup.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/index.d.ts +11 -37
- package/node_modules/@gdh/adapters/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/index.js +18 -90
- package/node_modules/@gdh/adapters/dist/index.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/inventory-sweep.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/inventory-sweep.js +1 -3
- package/node_modules/@gdh/adapters/dist/inventory-sweep.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/managed-surfaces.d.ts +32 -0
- package/node_modules/@gdh/adapters/dist/managed-surfaces.d.ts.map +1 -0
- package/node_modules/@gdh/adapters/dist/managed-surfaces.js +66 -0
- package/node_modules/@gdh/adapters/dist/managed-surfaces.js.map +1 -0
- package/node_modules/@gdh/adapters/dist/process-orchestration.d.ts +1 -1
- package/node_modules/@gdh/adapters/dist/process-orchestration.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/process-orchestration.js +3 -2
- package/node_modules/@gdh/adapters/dist/process-orchestration.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/self-update-mechanics.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/self-update-mechanics.js +11 -23
- package/node_modules/@gdh/adapters/dist/self-update-mechanics.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/skill-rendering.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/skill-rendering.js +2 -8
- package/node_modules/@gdh/adapters/dist/skill-rendering.js.map +1 -1
- package/node_modules/@gdh/adapters/dist/template-assets.js.map +1 -1
- package/node_modules/@gdh/adapters/package.json +7 -8
- package/node_modules/@gdh/authoring/dist/authoring-state-store.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/authoring-state-store.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/cache.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/cache.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/diagnostics-broker-contract.d.ts +2 -2
- package/node_modules/@gdh/authoring/dist/diagnostics-broker-contract.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/diagnostics-broker-contract.js +2 -2
- package/node_modules/@gdh/authoring/dist/diagnostics-broker-contract.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/diagnostics-broker.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/diagnostics-broker.js +15 -12
- package/node_modules/@gdh/authoring/dist/diagnostics-broker.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp-broker-snapshot.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp-broker-snapshot.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp-client.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp-client.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp-constants.d.ts +17 -0
- package/node_modules/@gdh/authoring/dist/lsp-constants.d.ts.map +1 -0
- package/node_modules/@gdh/authoring/dist/lsp-constants.js +17 -0
- package/node_modules/@gdh/authoring/dist/lsp-constants.js.map +1 -0
- package/node_modules/@gdh/authoring/dist/lsp-warmup.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp-warmup.js +2 -4
- package/node_modules/@gdh/authoring/dist/lsp-warmup.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp.js +30 -64
- package/node_modules/@gdh/authoring/dist/lsp.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/prepare.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/prepare.js +1 -3
- package/node_modules/@gdh/authoring/dist/prepare.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/project.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/project.js +4 -13
- package/node_modules/@gdh/authoring/dist/project.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/report.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/report.js +2 -11
- package/node_modules/@gdh/authoring/dist/report.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/scene-resource.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/scene-resource.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/tcp-port.d.ts +2 -0
- package/node_modules/@gdh/authoring/dist/tcp-port.d.ts.map +1 -0
- package/node_modules/@gdh/authoring/dist/tcp-port.js +23 -0
- package/node_modules/@gdh/authoring/dist/tcp-port.js.map +1 -0
- package/node_modules/@gdh/authoring/dist/warmup.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/warmup.js.map +1 -1
- package/node_modules/@gdh/authoring/package.json +2 -2
- package/node_modules/@gdh/cli/dist/args.d.ts +44 -0
- package/node_modules/@gdh/cli/dist/args.d.ts.map +1 -0
- package/node_modules/@gdh/cli/dist/args.js +124 -0
- package/node_modules/@gdh/cli/dist/args.js.map +1 -0
- package/node_modules/@gdh/cli/dist/bridge-session.d.ts +1 -1
- package/node_modules/@gdh/cli/dist/bridge-session.d.ts.map +1 -1
- package/node_modules/@gdh/cli/dist/bridge-session.js +9 -8
- package/node_modules/@gdh/cli/dist/bridge-session.js.map +1 -1
- package/node_modules/@gdh/cli/dist/index.d.ts +4 -52
- package/node_modules/@gdh/cli/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/cli/dist/index.js +8 -197
- package/node_modules/@gdh/cli/dist/index.js.map +1 -1
- package/node_modules/@gdh/cli/dist/io.d.ts +10 -0
- package/node_modules/@gdh/cli/dist/io.d.ts.map +1 -0
- package/node_modules/@gdh/cli/dist/io.js +26 -0
- package/node_modules/@gdh/cli/dist/io.js.map +1 -0
- package/node_modules/@gdh/cli/dist/mcp-cleanup.d.ts +3 -0
- package/node_modules/@gdh/cli/dist/mcp-cleanup.d.ts.map +1 -1
- package/node_modules/@gdh/cli/dist/mcp-cleanup.js +47 -0
- package/node_modules/@gdh/cli/dist/mcp-cleanup.js.map +1 -1
- package/node_modules/@gdh/cli/dist/migrate.d.ts +1 -1
- package/node_modules/@gdh/cli/dist/migrate.d.ts.map +1 -1
- package/node_modules/@gdh/cli/dist/migrate.js +23 -30
- package/node_modules/@gdh/cli/dist/migrate.js.map +1 -1
- package/node_modules/@gdh/cli/dist/self-update.d.ts.map +1 -1
- package/node_modules/@gdh/cli/dist/self-update.js +13 -20
- package/node_modules/@gdh/cli/dist/self-update.js.map +1 -1
- package/node_modules/@gdh/cli/dist/setup.d.ts.map +1 -1
- package/node_modules/@gdh/cli/dist/setup.js.map +1 -1
- package/node_modules/@gdh/cli/dist/status-command.d.ts +3 -0
- package/node_modules/@gdh/cli/dist/status-command.d.ts.map +1 -0
- package/node_modules/@gdh/cli/dist/status-command.js +44 -0
- package/node_modules/@gdh/cli/dist/status-command.js.map +1 -0
- package/node_modules/@gdh/cli/dist/update-banner.d.ts.map +1 -1
- package/node_modules/@gdh/cli/dist/update-banner.js +1 -1
- package/node_modules/@gdh/cli/dist/update-banner.js.map +1 -1
- package/node_modules/@gdh/cli/package.json +11 -11
- package/node_modules/@gdh/core/dist/dev-mode.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/dev-mode.js.map +1 -1
- package/node_modules/@gdh/core/dist/editor-operation-runner.d.ts +3 -0
- package/node_modules/@gdh/core/dist/editor-operation-runner.d.ts.map +1 -0
- package/node_modules/@gdh/core/dist/editor-operation-runner.js +682 -0
- package/node_modules/@gdh/core/dist/editor-operation-runner.js.map +1 -0
- package/node_modules/@gdh/core/dist/git-root.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/git-root.js +4 -1
- package/node_modules/@gdh/core/dist/git-root.js.map +1 -1
- package/node_modules/@gdh/core/dist/godot-docs-version.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/godot-docs-version.js.map +1 -1
- package/node_modules/@gdh/core/dist/godot-stderr-fatality.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/godot-stderr-fatality.js +1 -2
- package/node_modules/@gdh/core/dist/godot-stderr-fatality.js.map +1 -1
- package/node_modules/@gdh/core/dist/index.d.ts +10 -5
- package/node_modules/@gdh/core/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/index.js +15 -5
- package/node_modules/@gdh/core/dist/index.js.map +1 -1
- package/node_modules/@gdh/core/dist/managed-gitignore.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/managed-gitignore.js +4 -14
- package/node_modules/@gdh/core/dist/managed-gitignore.js.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/entries/s2c2_to_s2c3_rules_schema_v2_to_v3.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/entries/s2c2_to_s2c3_rules_schema_v2_to_v3.js +2 -2
- package/node_modules/@gdh/core/dist/migrations/entries/s2c2_to_s2c3_rules_schema_v2_to_v3.js.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/entries/s3c21_to_s3c22_canonical_hook_paths.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/entries/s3c21_to_s3c22_canonical_hook_paths.js +6 -14
- package/node_modules/@gdh/core/dist/migrations/entries/s3c21_to_s3c22_canonical_hook_paths.js.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/entries/s3c8_to_s3c9_register_runtime_bridge_autoload.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/entries/s3c8_to_s3c9_register_runtime_bridge_autoload.js +7 -23
- package/node_modules/@gdh/core/dist/migrations/entries/s3c8_to_s3c9_register_runtime_bridge_autoload.js.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/envelopes/envelope-output-validator.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/envelopes/envelope-output-validator.js.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/envelopes/index.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/envelopes/index.js +1 -2
- package/node_modules/@gdh/core/dist/migrations/envelopes/index.js.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/envelopes/types.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/golden-harness.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/golden-harness.js.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/managed-surface-classes.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/managed-surface-classes.js.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/managed-target-surface-inventory.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/managed-target-surface-inventory.js.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/probes.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/probes.js.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/registry.d.ts +1 -1
- package/node_modules/@gdh/core/dist/migrations/registry.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/migrations/registry.js +3 -6
- package/node_modules/@gdh/core/dist/migrations/registry.js.map +1 -1
- package/node_modules/@gdh/core/dist/official-docs.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/process-termination.d.ts +29 -0
- package/node_modules/@gdh/core/dist/process-termination.d.ts.map +1 -0
- package/node_modules/@gdh/core/dist/process-termination.js +125 -0
- package/node_modules/@gdh/core/dist/process-termination.js.map +1 -0
- package/node_modules/@gdh/core/dist/release-span-preview.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/release-span-preview.js +1 -1
- package/node_modules/@gdh/core/dist/release-span-preview.js.map +1 -1
- package/node_modules/@gdh/core/dist/release-span-update-contract.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/release-span-update-contract.js +5 -10
- package/node_modules/@gdh/core/dist/release-span-update-contract.js.map +1 -1
- package/node_modules/@gdh/core/dist/state/codex-retrust-reminder.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/state/codex-retrust-reminder.js.map +1 -1
- package/node_modules/@gdh/core/dist/state/migration-state.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/state/migration-state.js +3 -8
- package/node_modules/@gdh/core/dist/state/migration-state.js.map +1 -1
- package/node_modules/@gdh/core/dist/state/migration-trace.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/state/migration-trace.js +3 -8
- package/node_modules/@gdh/core/dist/state/migration-trace.js.map +1 -1
- package/node_modules/@gdh/core/dist/state/render-inventory.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/state/render-inventory.js.map +1 -1
- package/node_modules/@gdh/core/dist/update-cache.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/update-cache.js.map +1 -1
- package/node_modules/@gdh/core/dist/update-probe.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/update-probe.js +1 -3
- package/node_modules/@gdh/core/dist/update-probe.js.map +1 -1
- package/node_modules/@gdh/core/package.json +1 -1
- package/node_modules/@gdh/docs/dist/agent-contract.d.ts.map +1 -1
- package/node_modules/@gdh/docs/dist/agent-contract.js +2 -4
- package/node_modules/@gdh/docs/dist/agent-contract.js.map +1 -1
- package/node_modules/@gdh/docs/dist/files.d.ts +1 -1
- package/node_modules/@gdh/docs/dist/files.d.ts.map +1 -1
- package/node_modules/@gdh/docs/dist/guidance.js +1 -1
- package/node_modules/@gdh/docs/dist/guidance.js.map +1 -1
- package/node_modules/@gdh/docs/dist/index.d.ts +4 -4
- package/node_modules/@gdh/docs/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/docs/dist/index.js +3 -3
- package/node_modules/@gdh/docs/dist/index.js.map +1 -1
- package/node_modules/@gdh/docs/dist/official-docs.d.ts.map +1 -1
- package/node_modules/@gdh/docs/dist/official-docs.js +16 -5
- package/node_modules/@gdh/docs/dist/official-docs.js.map +1 -1
- package/node_modules/@gdh/docs/dist/query.d.ts.map +1 -1
- package/node_modules/@gdh/docs/dist/query.js +8 -3
- package/node_modules/@gdh/docs/dist/query.js.map +1 -1
- package/node_modules/@gdh/docs/dist/recovery-hints.d.ts.map +1 -1
- package/node_modules/@gdh/docs/dist/recovery-hints.js +0 -1
- package/node_modules/@gdh/docs/dist/recovery-hints.js.map +1 -1
- package/node_modules/@gdh/docs/dist/template-assets.js.map +1 -1
- package/node_modules/@gdh/docs/package.json +2 -2
- package/node_modules/@gdh/editor/dist/index.d.ts +1 -3
- package/node_modules/@gdh/editor/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/editor/dist/index.js +46 -683
- package/node_modules/@gdh/editor/dist/index.js.map +1 -1
- package/node_modules/@gdh/editor/package.json +2 -2
- package/node_modules/@gdh/mcp/dist/bridge-tools.d.ts +8 -1
- package/node_modules/@gdh/mcp/dist/bridge-tools.d.ts.map +1 -1
- package/node_modules/@gdh/mcp/dist/bridge-tools.js +81 -2
- package/node_modules/@gdh/mcp/dist/bridge-tools.js.map +1 -1
- package/node_modules/@gdh/mcp/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/mcp/dist/index.js +10 -77
- package/node_modules/@gdh/mcp/dist/index.js.map +1 -1
- package/node_modules/@gdh/mcp/package.json +8 -10
- package/node_modules/@gdh/observability/dist/guidance-audit.d.ts.map +1 -1
- package/node_modules/@gdh/observability/dist/guidance-audit.js +11 -21
- package/node_modules/@gdh/observability/dist/guidance-audit.js.map +1 -1
- package/node_modules/@gdh/observability/dist/index.d.ts +2 -2
- package/node_modules/@gdh/observability/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/observability/dist/index.js +1 -1
- package/node_modules/@gdh/observability/dist/index.js.map +1 -1
- package/node_modules/@gdh/observability/dist/runtime-bundles.d.ts.map +1 -1
- package/node_modules/@gdh/observability/dist/runtime-bundles.js +3 -10
- package/node_modules/@gdh/observability/dist/runtime-bundles.js.map +1 -1
- package/node_modules/@gdh/observability/dist/runtime-corpus.d.ts.map +1 -1
- package/node_modules/@gdh/observability/dist/runtime-corpus.js +1 -1
- package/node_modules/@gdh/observability/dist/runtime-corpus.js.map +1 -1
- package/node_modules/@gdh/observability/package.json +3 -2
- package/node_modules/@gdh/runtime/dist/bridge-broker-client.d.ts +2 -1
- package/node_modules/@gdh/runtime/dist/bridge-broker-client.d.ts.map +1 -1
- package/node_modules/@gdh/runtime/dist/bridge-broker-client.js +8 -1
- package/node_modules/@gdh/runtime/dist/bridge-broker-client.js.map +1 -1
- package/node_modules/@gdh/runtime/dist/bridge-broker.d.ts +2 -1
- package/node_modules/@gdh/runtime/dist/bridge-broker.d.ts.map +1 -1
- package/node_modules/@gdh/runtime/dist/bridge-broker.js +71 -21
- package/node_modules/@gdh/runtime/dist/bridge-broker.js.map +1 -1
- package/node_modules/@gdh/runtime/dist/bridge-surface.d.ts +1 -1
- package/node_modules/@gdh/runtime/dist/bridge-surface.d.ts.map +1 -1
- package/node_modules/@gdh/runtime/dist/bridge-surface.js +2 -2
- package/node_modules/@gdh/runtime/dist/bridge-surface.js.map +1 -1
- package/node_modules/@gdh/runtime/dist/docker-provider.d.ts +1 -1
- package/node_modules/@gdh/runtime/dist/docker-provider.d.ts.map +1 -1
- package/node_modules/@gdh/runtime/dist/docker-provider.js +5 -16
- package/node_modules/@gdh/runtime/dist/docker-provider.js.map +1 -1
- package/node_modules/@gdh/runtime/dist/index.d.ts +1 -1
- package/node_modules/@gdh/runtime/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/runtime/dist/index.js +65 -18
- package/node_modules/@gdh/runtime/dist/index.js.map +1 -1
- package/node_modules/@gdh/runtime/dist/knowledge-surface.d.ts.map +1 -1
- package/node_modules/@gdh/runtime/dist/knowledge-surface.js +21 -10
- package/node_modules/@gdh/runtime/dist/knowledge-surface.js.map +1 -1
- package/node_modules/@gdh/runtime/package.json +2 -3
- package/node_modules/@gdh/scan/dist/detect-existing-onboarding.d.ts.map +1 -1
- package/node_modules/@gdh/scan/dist/detect-existing-onboarding.js +1 -5
- package/node_modules/@gdh/scan/dist/detect-existing-onboarding.js.map +1 -1
- package/node_modules/@gdh/scan/dist/index.d.ts +3 -3
- package/node_modules/@gdh/scan/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/scan/dist/index.js +3 -3
- package/node_modules/@gdh/scan/dist/index.js.map +1 -1
- package/node_modules/@gdh/scan/dist/inventory-cache.js +1 -1
- package/node_modules/@gdh/scan/dist/inventory-cache.js.map +1 -1
- package/node_modules/@gdh/scan/dist/onboard.d.ts +1 -2
- package/node_modules/@gdh/scan/dist/onboard.d.ts.map +1 -1
- package/node_modules/@gdh/scan/dist/onboard.js +4 -5
- package/node_modules/@gdh/scan/dist/onboard.js.map +1 -1
- package/node_modules/@gdh/scan/dist/scan.d.ts.map +1 -1
- package/node_modules/@gdh/scan/dist/scan.js +4 -2
- package/node_modules/@gdh/scan/dist/scan.js.map +1 -1
- package/node_modules/@gdh/scan/package.json +3 -3
- package/node_modules/@gdh/verify/dist/corpus.d.ts.map +1 -1
- package/node_modules/@gdh/verify/dist/corpus.js +7 -6
- package/node_modules/@gdh/verify/dist/corpus.js.map +1 -1
- package/node_modules/@gdh/verify/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/verify/dist/index.js +0 -1
- package/node_modules/@gdh/verify/dist/index.js.map +1 -1
- package/node_modules/@gdh/verify/dist/readiness.d.ts.map +1 -1
- package/node_modules/@gdh/verify/dist/readiness.js.map +1 -1
- package/node_modules/@gdh/verify/dist/scenarios.d.ts +1 -1
- package/node_modules/@gdh/verify/dist/scenarios.d.ts.map +1 -1
- package/node_modules/@gdh/verify/dist/scenarios.js +14 -11
- package/node_modules/@gdh/verify/dist/scenarios.js.map +1 -1
- package/node_modules/@gdh/verify/package.json +6 -7
- package/node_modules/@hono/node-server/dist/index.js +22 -0
- package/node_modules/@hono/node-server/dist/index.mjs +22 -0
- package/node_modules/@hono/node-server/dist/listener.js +22 -0
- package/node_modules/@hono/node-server/dist/listener.mjs +22 -0
- package/node_modules/@hono/node-server/dist/request.js +11 -0
- package/node_modules/@hono/node-server/dist/request.mjs +11 -0
- package/node_modules/@hono/node-server/dist/response.js +11 -0
- package/node_modules/@hono/node-server/dist/response.mjs +11 -0
- package/node_modules/@hono/node-server/dist/server.js +22 -0
- package/node_modules/@hono/node-server/dist/server.mjs +22 -0
- package/node_modules/@hono/node-server/dist/utils.d.mts +2 -2
- package/node_modules/@hono/node-server/dist/utils.d.ts +2 -2
- package/node_modules/@hono/node-server/dist/vercel.js +22 -0
- package/node_modules/@hono/node-server/dist/vercel.mjs +22 -0
- package/node_modules/@hono/node-server/package.json +1 -1
- package/node_modules/ajv/README.md +1 -1
- package/node_modules/ajv/dist/core.js +1 -1
- package/node_modules/ajv/dist/core.js.map +1 -1
- package/node_modules/ajv/lib/core.ts +1 -1
- package/node_modules/ajv/package.json +2 -3
- package/node_modules/eventsource-parser/LICENSE +1 -1
- package/node_modules/eventsource-parser/dist/index.cjs +104 -44
- package/node_modules/eventsource-parser/dist/index.cjs.map +1 -1
- package/node_modules/eventsource-parser/dist/index.d.cts +23 -21
- package/node_modules/eventsource-parser/dist/index.d.ts +23 -21
- package/node_modules/eventsource-parser/dist/index.js +104 -44
- package/node_modules/eventsource-parser/dist/index.js.map +1 -1
- package/node_modules/eventsource-parser/dist/stream.d.cts +22 -19
- package/node_modules/eventsource-parser/dist/stream.d.ts +22 -19
- package/node_modules/eventsource-parser/package.json +54 -77
- package/node_modules/eventsource-parser/src/parse.ts +270 -107
- package/node_modules/express-rate-limit/dist/index.cjs +51 -10
- package/node_modules/express-rate-limit/dist/index.d.cts +31 -1
- package/node_modules/express-rate-limit/dist/index.d.mts +31 -1
- package/node_modules/express-rate-limit/dist/index.d.ts +31 -1
- package/node_modules/express-rate-limit/dist/index.mjs +51 -10
- package/node_modules/express-rate-limit/package.json +3 -2
- package/node_modules/express-rate-limit/readme.md +3 -0
- package/node_modules/fast-string-truncated-width/dist/index.js +36 -96
- package/node_modules/fast-string-truncated-width/dist/types.d.ts +0 -3
- package/node_modules/fast-string-truncated-width/dist/utils.d.ts +3 -3
- package/node_modules/fast-string-truncated-width/dist/utils.js +14 -9
- package/node_modules/fast-string-truncated-width/package.json +1 -1
- package/node_modules/fast-string-truncated-width/readme.md +2 -3
- package/node_modules/fast-string-width/package.json +2 -2
- package/node_modules/fast-string-width/readme.md +0 -3
- package/node_modules/fast-uri/.github/workflows/ci.yml +12 -7
- package/node_modules/fast-uri/.github/workflows/lock-threads.yml +19 -0
- package/node_modules/fast-uri/.github/workflows/package-manager-ci.yml +1 -1
- package/node_modules/fast-uri/LICENSE +1 -3
- package/node_modules/fast-uri/README.md +13 -4
- package/node_modules/fast-uri/index.js +90 -24
- package/node_modules/fast-uri/lib/utils.js +129 -22
- package/node_modules/fast-uri/package.json +3 -4
- package/node_modules/fast-wrap-ansi/lib/main.js +4 -1
- package/node_modules/fast-wrap-ansi/lib/main.js.map +1 -1
- package/node_modules/fast-wrap-ansi/package.json +2 -2
- package/node_modules/get-intrinsic/CHANGELOG.md +0 -7
- package/node_modules/get-intrinsic/index.js +13 -8
- package/node_modules/get-intrinsic/package.json +4 -7
- package/node_modules/hasown/CHANGELOG.md +11 -0
- package/node_modules/hasown/eslint.config.mjs +6 -0
- package/node_modules/hasown/index.d.ts +1 -0
- package/node_modules/hasown/package.json +14 -14
- package/node_modules/hono/dist/adapter/aws-lambda/handler.js +9 -2
- package/node_modules/hono/dist/cjs/adapter/aws-lambda/handler.js +9 -2
- package/node_modules/hono/dist/cjs/helper/ssg/ssg.js +2 -0
- package/node_modules/hono/dist/cjs/jsx/base.js +7 -1
- package/node_modules/hono/dist/cjs/jsx/dom/render.js +22 -9
- package/node_modules/hono/dist/cjs/jsx/jsx-runtime.js +3 -0
- package/node_modules/hono/dist/cjs/jsx/utils.js +155 -5
- package/node_modules/hono/dist/cjs/middleware/body-limit/index.js +21 -30
- package/node_modules/hono/dist/cjs/middleware/cache/index.js +11 -3
- package/node_modules/hono/dist/cjs/middleware/cors/index.js +2 -5
- package/node_modules/hono/dist/cjs/middleware/method-override/index.js +1 -1
- package/node_modules/hono/dist/cjs/middleware/trailing-slash/index.js +2 -2
- package/node_modules/hono/dist/cjs/utils/jwt/jws.js +1 -1
- package/node_modules/hono/dist/cjs/utils/jwt/jwt.js +12 -6
- package/node_modules/hono/dist/helper/ssg/ssg.js +2 -0
- package/node_modules/hono/dist/jsx/base.js +13 -2
- package/node_modules/hono/dist/jsx/dom/render.js +22 -9
- package/node_modules/hono/dist/jsx/jsx-runtime.js +4 -1
- package/node_modules/hono/dist/jsx/utils.js +153 -5
- package/node_modules/hono/dist/middleware/body-limit/index.js +21 -30
- package/node_modules/hono/dist/middleware/cache/index.js +11 -3
- package/node_modules/hono/dist/middleware/cors/index.js +2 -5
- package/node_modules/hono/dist/middleware/method-override/index.js +1 -1
- package/node_modules/hono/dist/middleware/trailing-slash/index.js +2 -2
- package/node_modules/hono/dist/tsconfig.build.tsbuildinfo +1 -1
- package/node_modules/hono/dist/types/jsx/utils.d.ts +3 -1
- package/node_modules/hono/dist/types/middleware/cache/index.d.ts +2 -0
- package/node_modules/hono/dist/types/middleware/cors/index.d.ts +1 -1
- package/node_modules/hono/dist/types/middleware/trailing-slash/index.d.ts +16 -0
- package/node_modules/hono/dist/types/types.d.ts +116 -116
- package/node_modules/hono/dist/utils/jwt/jws.js +1 -1
- package/node_modules/hono/dist/utils/jwt/jwt.js +12 -6
- package/node_modules/hono/package.json +1 -1
- package/node_modules/ip-address/README.md +249 -76
- package/node_modules/ip-address/dist/address-error.d.ts +0 -1
- package/node_modules/ip-address/dist/address-error.js.map +1 -1
- package/node_modules/ip-address/dist/common.d.ts +6 -1
- package/node_modules/ip-address/dist/common.js +21 -0
- package/node_modules/ip-address/dist/common.js.map +1 -1
- package/node_modules/ip-address/dist/ip-address.d.ts +0 -1
- package/node_modules/ip-address/dist/ip-address.js.map +1 -1
- package/node_modules/ip-address/dist/ipv4.d.ts +115 -57
- package/node_modules/ip-address/dist/ipv4.js +193 -68
- package/node_modules/ip-address/dist/ipv4.js.map +1 -1
- package/node_modules/ip-address/dist/ipv6.d.ts +172 -111
- package/node_modules/ip-address/dist/ipv6.js +345 -131
- package/node_modules/ip-address/dist/ipv6.js.map +1 -1
- package/node_modules/ip-address/dist/v4/constants.d.ts +0 -1
- package/node_modules/ip-address/dist/v4/constants.js.map +1 -1
- package/node_modules/ip-address/dist/v6/constants.d.ts +0 -1
- package/node_modules/ip-address/dist/v6/constants.js +5 -0
- package/node_modules/ip-address/dist/v6/constants.js.map +1 -1
- package/node_modules/ip-address/dist/v6/helpers.d.ts +1 -1
- package/node_modules/ip-address/dist/v6/helpers.js +12 -3
- package/node_modules/ip-address/dist/v6/helpers.js.map +1 -1
- package/node_modules/ip-address/dist/v6/regular-expressions.d.ts +0 -1
- package/node_modules/ip-address/dist/v6/regular-expressions.js.map +1 -1
- package/node_modules/ip-address/package.json +45 -35
- package/node_modules/jose/dist/webapi/jwks/remote.js +1 -1
- package/node_modules/jose/dist/webapi/lib/pbes2kw.js +3 -0
- package/node_modules/jose/package.json +1 -1
- package/node_modules/yaml/browser/dist/compose/resolve-flow-scalar.js +5 -3
- package/node_modules/yaml/browser/dist/nodes/Alias.js +2 -0
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/merge.js +11 -8
- package/node_modules/yaml/browser/dist/stringify/stringifyNumber.js +2 -1
- package/node_modules/yaml/dist/compose/resolve-flow-scalar.js +5 -3
- package/node_modules/yaml/dist/nodes/Alias.js +2 -0
- package/node_modules/yaml/dist/nodes/Scalar.d.ts +5 -1
- package/node_modules/yaml/dist/schema/yaml-1.1/merge.js +10 -7
- package/node_modules/yaml/dist/stringify/stringifyNumber.js +2 -1
- package/node_modules/yaml/package.json +1 -1
- package/node_modules/zod/README.md +1 -18
- package/node_modules/zod/locales/package.json +2 -1
- package/node_modules/zod/mini/package.json +2 -1
- package/node_modules/zod/package.json +1 -1
- package/node_modules/zod/src/v4/classic/errors.ts +2 -2
- package/node_modules/zod/src/v4/classic/external.ts +1 -0
- package/node_modules/zod/src/v4/classic/from-json-schema.ts +39 -23
- package/node_modules/zod/src/v4/classic/parse.ts +6 -6
- package/node_modules/zod/src/v4/classic/schemas.ts +414 -151
- package/node_modules/zod/src/v4/core/api.ts +31 -6
- package/node_modules/zod/src/v4/core/checks.ts +1 -1
- package/node_modules/zod/src/v4/core/core.ts +17 -2
- package/node_modules/zod/src/v4/core/errors.ts +31 -24
- package/node_modules/zod/src/v4/core/json-schema-processors.ts +17 -18
- package/node_modules/zod/src/v4/core/parse.ts +7 -7
- package/node_modules/zod/src/v4/core/regexes.ts +8 -1
- package/node_modules/zod/src/v4/core/schemas.ts +263 -71
- package/node_modules/zod/src/v4/core/to-json-schema.ts +10 -1
- package/node_modules/zod/src/v4/core/util.ts +52 -35
- package/node_modules/zod/src/v4/core/versions.ts +2 -2
- package/node_modules/zod/src/v4/locales/el.ts +121 -0
- package/node_modules/zod/src/v4/locales/en.ts +4 -0
- package/node_modules/zod/src/v4/locales/fr.ts +24 -8
- package/node_modules/zod/src/v4/locales/hr.ts +131 -0
- package/node_modules/zod/src/v4/locales/index.ts +3 -0
- package/node_modules/zod/src/v4/locales/it.ts +1 -1
- package/node_modules/zod/src/v4/locales/ka.ts +8 -8
- package/node_modules/zod/src/v4/locales/ro.ts +129 -0
- package/node_modules/zod/src/v4/locales/uz.ts +1 -0
- package/node_modules/zod/src/v4/mini/external.ts +1 -0
- package/node_modules/zod/src/v4/mini/schemas.ts +56 -25
- package/node_modules/zod/v3/package.json +2 -1
- package/node_modules/zod/v4/classic/errors.js +2 -2
- package/node_modules/zod/v4/classic/external.d.cts +1 -0
- package/node_modules/zod/v4/classic/external.d.ts +1 -0
- package/node_modules/zod/v4/classic/from-json-schema.cjs +31 -16
- package/node_modules/zod/v4/classic/from-json-schema.js +31 -16
- package/node_modules/zod/v4/classic/package.json +2 -1
- package/node_modules/zod/v4/classic/schemas.cjs +358 -119
- package/node_modules/zod/v4/classic/schemas.d.cts +42 -14
- package/node_modules/zod/v4/classic/schemas.d.ts +42 -14
- package/node_modules/zod/v4/classic/schemas.js +356 -118
- package/node_modules/zod/v4/core/api.cjs +7 -2
- package/node_modules/zod/v4/core/api.d.cts +26 -5
- package/node_modules/zod/v4/core/api.d.ts +26 -5
- package/node_modules/zod/v4/core/api.js +7 -2
- package/node_modules/zod/v4/core/checks.d.cts +1 -1
- package/node_modules/zod/v4/core/checks.d.ts +1 -1
- package/node_modules/zod/v4/core/core.cjs +3 -1
- package/node_modules/zod/v4/core/core.js +4 -2
- package/node_modules/zod/v4/core/errors.cjs +26 -23
- package/node_modules/zod/v4/core/errors.d.cts +1 -0
- package/node_modules/zod/v4/core/errors.d.ts +1 -0
- package/node_modules/zod/v4/core/errors.js +26 -23
- package/node_modules/zod/v4/core/json-schema-processors.cjs +16 -20
- package/node_modules/zod/v4/core/json-schema-processors.js +16 -20
- package/node_modules/zod/v4/core/package.json +2 -1
- package/node_modules/zod/v4/core/parse.cjs +7 -7
- package/node_modules/zod/v4/core/parse.js +7 -7
- package/node_modules/zod/v4/core/regexes.cjs +9 -3
- package/node_modules/zod/v4/core/regexes.d.cts +6 -0
- package/node_modules/zod/v4/core/regexes.d.ts +6 -0
- package/node_modules/zod/v4/core/regexes.js +7 -1
- package/node_modules/zod/v4/core/schemas.cjs +211 -65
- package/node_modules/zod/v4/core/schemas.d.cts +39 -1
- package/node_modules/zod/v4/core/schemas.d.ts +39 -1
- package/node_modules/zod/v4/core/schemas.js +210 -64
- package/node_modules/zod/v4/core/to-json-schema.cjs +12 -1
- package/node_modules/zod/v4/core/to-json-schema.js +12 -1
- package/node_modules/zod/v4/core/util.cjs +54 -30
- package/node_modules/zod/v4/core/util.d.cts +1 -0
- package/node_modules/zod/v4/core/util.d.ts +1 -0
- package/node_modules/zod/v4/core/util.js +55 -32
- package/node_modules/zod/v4/core/versions.cjs +2 -2
- package/node_modules/zod/v4/core/versions.d.cts +1 -1
- package/node_modules/zod/v4/core/versions.d.ts +1 -1
- package/node_modules/zod/v4/core/versions.js +2 -2
- package/node_modules/zod/v4/locales/el.cjs +136 -0
- package/node_modules/zod/v4/locales/el.d.cts +5 -0
- package/node_modules/zod/v4/locales/el.d.ts +4 -0
- package/node_modules/zod/v4/locales/el.js +109 -0
- package/node_modules/zod/v4/locales/en.cjs +4 -0
- package/node_modules/zod/v4/locales/en.js +4 -0
- package/node_modules/zod/v4/locales/fr.cjs +24 -7
- package/node_modules/zod/v4/locales/fr.js +24 -7
- package/node_modules/zod/v4/locales/hr.cjs +149 -0
- package/node_modules/zod/v4/locales/hr.d.cts +5 -0
- package/node_modules/zod/v4/locales/hr.d.ts +4 -0
- package/node_modules/zod/v4/locales/hr.js +122 -0
- package/node_modules/zod/v4/locales/index.cjs +8 -1
- package/node_modules/zod/v4/locales/index.d.cts +3 -0
- package/node_modules/zod/v4/locales/index.d.ts +3 -0
- package/node_modules/zod/v4/locales/index.js +3 -0
- package/node_modules/zod/v4/locales/it.cjs +1 -1
- package/node_modules/zod/v4/locales/it.js +1 -1
- package/node_modules/zod/v4/locales/ka.cjs +8 -8
- package/node_modules/zod/v4/locales/ka.js +8 -8
- package/node_modules/zod/v4/locales/package.json +2 -1
- package/node_modules/zod/v4/locales/ro.cjs +146 -0
- package/node_modules/zod/v4/locales/ro.d.cts +5 -0
- package/node_modules/zod/v4/locales/ro.d.ts +4 -0
- package/node_modules/zod/v4/locales/ro.js +119 -0
- package/node_modules/zod/v4/locales/uz.cjs +1 -0
- package/node_modules/zod/v4/locales/uz.js +1 -0
- package/node_modules/zod/v4/mini/external.d.cts +1 -0
- package/node_modules/zod/v4/mini/external.d.ts +1 -0
- package/node_modules/zod/v4/mini/package.json +2 -1
- package/node_modules/zod/v4/mini/schemas.cjs +41 -4
- package/node_modules/zod/v4/mini/schemas.d.cts +28 -10
- package/node_modules/zod/v4/mini/schemas.d.ts +28 -10
- package/node_modules/zod/v4/mini/schemas.js +40 -4
- package/node_modules/zod/v4/package.json +2 -1
- package/node_modules/zod/v4-mini/package.json +2 -1
- package/package.json +12 -12
- package/node_modules/async-function/.eslintrc +0 -16
- package/node_modules/async-function/.github/FUNDING.yml +0 -12
- package/node_modules/async-function/.nycrc +0 -9
- package/node_modules/async-function/CHANGELOG.md +0 -16
- package/node_modules/async-function/LICENSE +0 -21
- package/node_modules/async-function/README.md +0 -51
- package/node_modules/async-function/index.d.mts +0 -3
- package/node_modules/async-function/index.d.ts +0 -13
- package/node_modules/async-function/index.js +0 -8
- package/node_modules/async-function/index.mjs +0 -4
- package/node_modules/async-function/legacy.js +0 -18
- package/node_modules/async-function/package.json +0 -86
- package/node_modules/async-function/require.mjs +0 -5
- package/node_modules/async-function/tsconfig.json +0 -9
- package/node_modules/async-generator-function/.eslintrc +0 -26
- package/node_modules/async-generator-function/.github/FUNDING.yml +0 -12
- package/node_modules/async-generator-function/.nycrc +0 -9
- package/node_modules/async-generator-function/CHANGELOG.md +0 -15
- package/node_modules/async-generator-function/LICENSE +0 -21
- package/node_modules/async-generator-function/README.md +0 -52
- package/node_modules/async-generator-function/index.d.mts +0 -3
- package/node_modules/async-generator-function/index.d.ts +0 -22
- package/node_modules/async-generator-function/index.js +0 -8
- package/node_modules/async-generator-function/index.mjs +0 -4
- package/node_modules/async-generator-function/legacy.js +0 -18
- package/node_modules/async-generator-function/package.json +0 -87
- package/node_modules/async-generator-function/require.mjs +0 -5
- package/node_modules/async-generator-function/tsconfig.json +0 -9
- package/node_modules/fast-uri/.github/.stale.yml +0 -21
- package/node_modules/fast-uri/.github/tests_checker.yml +0 -8
- package/node_modules/generator-function/.eslintrc +0 -16
- package/node_modules/generator-function/.github/FUNDING.yml +0 -12
- package/node_modules/generator-function/.nycrc +0 -9
- package/node_modules/generator-function/CHANGELOG.md +0 -27
- package/node_modules/generator-function/LICENSE.md +0 -7
- package/node_modules/generator-function/README.md +0 -51
- package/node_modules/generator-function/index.d.mts +0 -3
- package/node_modules/generator-function/index.d.ts +0 -3
- package/node_modules/generator-function/index.js +0 -8
- package/node_modules/generator-function/index.mjs +0 -4
- package/node_modules/generator-function/legacy.js +0 -18
- package/node_modules/generator-function/package.json +0 -88
- package/node_modules/generator-function/require.mjs +0 -5
- package/node_modules/generator-function/tsconfig.json +0 -9
- package/node_modules/hasown/.eslintrc +0 -5
- package/node_modules/ip-address/dist/address-error.d.ts.map +0 -1
- package/node_modules/ip-address/dist/common.d.ts.map +0 -1
- package/node_modules/ip-address/dist/ip-address.d.ts.map +0 -1
- package/node_modules/ip-address/dist/ipv4.d.ts.map +0 -1
- package/node_modules/ip-address/dist/ipv6.d.ts.map +0 -1
- package/node_modules/ip-address/dist/v4/constants.d.ts.map +0 -1
- package/node_modules/ip-address/dist/v6/constants.d.ts.map +0 -1
- package/node_modules/ip-address/dist/v6/helpers.d.ts.map +0 -1
- package/node_modules/ip-address/dist/v6/regular-expressions.d.ts.map +0 -1
- package/node_modules/ip-address/src/address-error.ts +0 -11
- package/node_modules/ip-address/src/common.ts +0 -55
- package/node_modules/ip-address/src/ip-address.ts +0 -7
- package/node_modules/ip-address/src/ipv4.ts +0 -394
- package/node_modules/ip-address/src/ipv6.ts +0 -1212
- package/node_modules/ip-address/src/v4/constants.ts +0 -7
- package/node_modules/ip-address/src/v6/constants.ts +0 -79
- package/node_modules/ip-address/src/v6/helpers.ts +0 -48
- package/node_modules/ip-address/src/v6/regular-expressions.ts +0 -94
- /package/node_modules/{cross-spawn/node_modules/isexe → isexe}/.npmignore +0 -0
- /package/node_modules/{cross-spawn/node_modules/isexe → isexe}/LICENSE +0 -0
- /package/node_modules/{cross-spawn/node_modules/isexe → isexe}/README.md +0 -0
- /package/node_modules/{cross-spawn/node_modules/isexe → isexe}/index.js +0 -0
- /package/node_modules/{cross-spawn/node_modules/isexe → isexe}/mode.js +0 -0
- /package/node_modules/{cross-spawn/node_modules/isexe → isexe}/package.json +0 -0
- /package/node_modules/{cross-spawn/node_modules/isexe → isexe}/windows.js +0 -0
- /package/node_modules/{cross-spawn/node_modules/which → which}/LICENSE +0 -0
- /package/node_modules/{cross-spawn/node_modules/which → which}/README.md +0 -0
- /package/node_modules/{cross-spawn/node_modules/which → which}/bin/node-which +0 -0
- /package/node_modules/{cross-spawn/node_modules/which → which}/package.json +0 -0
- /package/node_modules/{cross-spawn/node_modules/which → which}/which.js +0 -0
|
@@ -1,12 +1,34 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eventsource-parser",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.8",
|
|
4
4
|
"description": "Streaming, source-agnostic EventSource/Server-Sent Events parser",
|
|
5
|
-
"
|
|
5
|
+
"keywords": [
|
|
6
|
+
"eventsource",
|
|
7
|
+
"server-sent-events",
|
|
8
|
+
"sse"
|
|
9
|
+
],
|
|
10
|
+
"homepage": "https://github.com/rexxars/eventsource-parser#readme",
|
|
11
|
+
"bugs": {
|
|
12
|
+
"url": "https://github.com/rexxars/eventsource-parser/issues"
|
|
13
|
+
},
|
|
14
|
+
"license": "MIT",
|
|
15
|
+
"author": "Espen Hovlandsdal <espen@hovlandsdal.com>",
|
|
16
|
+
"repository": {
|
|
17
|
+
"type": "git",
|
|
18
|
+
"url": "git+ssh://git@github.com/rexxars/eventsource-parser.git"
|
|
19
|
+
},
|
|
20
|
+
"files": [
|
|
21
|
+
"dist",
|
|
22
|
+
"!dist/stats.html",
|
|
23
|
+
"!dist/index.min.js",
|
|
24
|
+
"src",
|
|
25
|
+
"stream.js"
|
|
26
|
+
],
|
|
6
27
|
"type": "module",
|
|
7
|
-
"
|
|
8
|
-
"module": "./dist/index.js",
|
|
28
|
+
"sideEffects": false,
|
|
9
29
|
"main": "./dist/index.cjs",
|
|
30
|
+
"module": "./dist/index.js",
|
|
31
|
+
"types": "./dist/index.d.ts",
|
|
10
32
|
"exports": {
|
|
11
33
|
".": {
|
|
12
34
|
"source": "./src/index.ts",
|
|
@@ -22,33 +44,16 @@
|
|
|
22
44
|
},
|
|
23
45
|
"./package.json": "./package.json"
|
|
24
46
|
},
|
|
25
|
-
"typesVersions": {
|
|
26
|
-
"*": {
|
|
27
|
-
"stream": [
|
|
28
|
-
"./dist/stream.d.ts"
|
|
29
|
-
]
|
|
30
|
-
}
|
|
31
|
-
},
|
|
32
|
-
"engines": {
|
|
33
|
-
"node": ">=18.0.0"
|
|
34
|
-
},
|
|
35
|
-
"browserslist": [
|
|
36
|
-
"node >= 20",
|
|
37
|
-
"chrome >= 71",
|
|
38
|
-
"safari >= 14.1",
|
|
39
|
-
"firefox >= 105",
|
|
40
|
-
"edge >= 79"
|
|
41
|
-
],
|
|
42
|
-
"files": [
|
|
43
|
-
"dist",
|
|
44
|
-
"!dist/stats.html",
|
|
45
|
-
"src",
|
|
46
|
-
"stream.js"
|
|
47
|
-
],
|
|
48
47
|
"scripts": {
|
|
49
48
|
"build": "pkg-utils build && pkg-utils --strict",
|
|
50
49
|
"clean": "rimraf dist coverage",
|
|
51
|
-
"
|
|
50
|
+
"check": "npm run clean && npm run format && npm run lint && npm run build && vitest run",
|
|
51
|
+
"format": "oxfmt",
|
|
52
|
+
"format:check": "oxfmt --check",
|
|
53
|
+
"bench": "node --expose-gc --experimental-strip-types --no-warnings=ExperimentalWarning bench/parse.bench.ts",
|
|
54
|
+
"bundle-size": "node --experimental-strip-types --no-warnings=ExperimentalWarning scripts/bundle-size.ts",
|
|
55
|
+
"knip": "knip",
|
|
56
|
+
"lint": "oxlint && tsc --noEmit",
|
|
52
57
|
"posttest": "npm run lint",
|
|
53
58
|
"prebuild": "npm run clean",
|
|
54
59
|
"prepublishOnly": "npm run build",
|
|
@@ -57,59 +62,31 @@
|
|
|
57
62
|
"test:deno": "deno run --allow-write --allow-net --allow-run --allow-sys --allow-ffi --allow-env --allow-read npm:vitest",
|
|
58
63
|
"test:node": "vitest --reporter=verbose"
|
|
59
64
|
},
|
|
60
|
-
"author": "Espen Hovlandsdal <espen@hovlandsdal.com>",
|
|
61
|
-
"keywords": [
|
|
62
|
-
"sse",
|
|
63
|
-
"eventsource",
|
|
64
|
-
"server-sent-events"
|
|
65
|
-
],
|
|
66
65
|
"devDependencies": {
|
|
67
|
-
"@sanity/pkg-utils": "^
|
|
68
|
-
"@sanity/semantic-release-preset": "^
|
|
66
|
+
"@sanity/pkg-utils": "^10.4.15",
|
|
67
|
+
"@sanity/semantic-release-preset": "^6.0.0",
|
|
68
|
+
"@sanity/tsconfig": "^2.1.0",
|
|
69
69
|
"@types/node": "^20.19.0",
|
|
70
|
-
"@typescript-eslint/eslint-plugin": "^7.0.0",
|
|
71
|
-
"@typescript-eslint/parser": "^7.0.0",
|
|
72
|
-
"eslint": "^8.51.0",
|
|
73
|
-
"eslint-config-prettier": "^9.1.0",
|
|
74
|
-
"eslint-config-sanity": "^7.1.2",
|
|
75
70
|
"eventsource-encoder": "^1.0.1",
|
|
76
|
-
"
|
|
77
|
-
"
|
|
71
|
+
"knip": "^6.4.1",
|
|
72
|
+
"mitata": "^1.0.34",
|
|
73
|
+
"oxfmt": "^0.45.0",
|
|
74
|
+
"oxlint": "^1.60.0",
|
|
75
|
+
"rimraf": "^6.1.3",
|
|
78
76
|
"rollup-plugin-visualizer": "^6.0.3",
|
|
79
|
-
"semantic-release": "^
|
|
80
|
-
"
|
|
81
|
-
"
|
|
82
|
-
|
|
83
|
-
"homepage": "https://github.com/rexxars/eventsource-parser#readme",
|
|
84
|
-
"bugs": {
|
|
85
|
-
"url": "https://github.com/rexxars/eventsource-parser/issues"
|
|
86
|
-
},
|
|
87
|
-
"repository": {
|
|
88
|
-
"type": "git",
|
|
89
|
-
"url": "git+ssh://git@github.com/rexxars/eventsource-parser.git"
|
|
90
|
-
},
|
|
91
|
-
"license": "MIT",
|
|
92
|
-
"prettier": {
|
|
93
|
-
"bracketSpacing": false,
|
|
94
|
-
"printWidth": 100,
|
|
95
|
-
"semi": false,
|
|
96
|
-
"singleQuote": true
|
|
77
|
+
"semantic-release": "^25.0.3",
|
|
78
|
+
"terser": "^5.46.1",
|
|
79
|
+
"typescript": "^5.9.3",
|
|
80
|
+
"vitest": "^4.1.4"
|
|
97
81
|
},
|
|
98
|
-
"
|
|
99
|
-
"
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
"
|
|
107
|
-
"sanity",
|
|
108
|
-
"sanity/typescript",
|
|
109
|
-
"prettier"
|
|
110
|
-
],
|
|
111
|
-
"ignorePatterns": [
|
|
112
|
-
"lib/**/"
|
|
113
|
-
]
|
|
82
|
+
"browserslist": [
|
|
83
|
+
"node >= 18",
|
|
84
|
+
"chrome >= 71",
|
|
85
|
+
"safari >= 14.1",
|
|
86
|
+
"firefox >= 105",
|
|
87
|
+
"edge >= 79"
|
|
88
|
+
],
|
|
89
|
+
"engines": {
|
|
90
|
+
"node": ">=18.0.0"
|
|
114
91
|
}
|
|
115
92
|
}
|
|
@@ -5,7 +5,12 @@
|
|
|
5
5
|
import {ParseError} from './errors.ts'
|
|
6
6
|
import type {EventSourceParser, ParserCallbacks} from './types.ts'
|
|
7
7
|
|
|
8
|
-
//
|
|
8
|
+
// ASCII codes used in the hot parsing paths.
|
|
9
|
+
const LF = 10
|
|
10
|
+
const CR = 13
|
|
11
|
+
const SPACE = 32
|
|
12
|
+
|
|
13
|
+
// oxlint-disable-next-line no-unused-vars
|
|
9
14
|
function noop(_arg: unknown) {
|
|
10
15
|
// intentional noop
|
|
11
16
|
}
|
|
@@ -31,66 +36,247 @@ export function createParser(callbacks: ParserCallbacks): EventSourceParser {
|
|
|
31
36
|
|
|
32
37
|
const {onEvent = noop, onError = noop, onRetry = noop, onComment} = callbacks
|
|
33
38
|
|
|
34
|
-
|
|
39
|
+
// Trailing bytes from prior `feed()` calls that did not yet form a complete line.
|
|
40
|
+
// Stored as an array of fragments and only joined when a line terminator arrives.
|
|
41
|
+
// Concatenating per-feed (`prefix + chunk`) is O(N²) when a single SSE line spans
|
|
42
|
+
// many chunks (e.g. a large `data:` payload streamed in tiny slices, or an MCP-style
|
|
43
|
+
// server that emits one giant content block). Buffering as fragments + joining once
|
|
44
|
+
// makes the same workload linear.
|
|
45
|
+
const pendingFragments: string[] = []
|
|
35
46
|
|
|
36
47
|
let isFirstChunk = true
|
|
37
48
|
let id: string | undefined
|
|
38
49
|
let data = ''
|
|
39
|
-
let
|
|
50
|
+
let dataLines = 0
|
|
51
|
+
let eventType: string | undefined
|
|
40
52
|
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
53
|
+
/**
|
|
54
|
+
* Feeds a chunk of the SSE stream to the parser. Any trailing bytes that do
|
|
55
|
+
* not yet form a complete line are held back and prepended to the next chunk,
|
|
56
|
+
* so callers can pass arbitrary slices of the stream without worrying about
|
|
57
|
+
* line boundaries.
|
|
58
|
+
*
|
|
59
|
+
* Per the SSE spec, a UTF-8 BOM (0xEF 0xBB 0xBF) at the start of the very
|
|
60
|
+
* first chunk is stripped before parsing.
|
|
61
|
+
*
|
|
62
|
+
* @see https://html.spec.whatwg.org/multipage/server-sent-events.html#parsing-an-event-stream
|
|
63
|
+
*/
|
|
64
|
+
function feed(chunk: string) {
|
|
65
|
+
if (isFirstChunk) {
|
|
66
|
+
isFirstChunk = false
|
|
67
|
+
// Match and strip UTF-8 BOM from the start of the stream, if present.
|
|
68
|
+
// (Per the spec, this is only valid at the very start of the stream)
|
|
69
|
+
if (
|
|
70
|
+
chunk.charCodeAt(0) === 0xef &&
|
|
71
|
+
chunk.charCodeAt(1) === 0xbb &&
|
|
72
|
+
chunk.charCodeAt(2) === 0xbf
|
|
73
|
+
) {
|
|
74
|
+
chunk = chunk.slice(3)
|
|
75
|
+
}
|
|
76
|
+
}
|
|
44
77
|
|
|
45
|
-
//
|
|
46
|
-
//
|
|
47
|
-
|
|
78
|
+
// Hot path: no buffered prefix from a prior partial line. Hand the chunk
|
|
79
|
+
// straight to `processLines`, exactly like the original implementation.
|
|
80
|
+
// Zero new work in the common case (every chunk ends with `\n\n`).
|
|
81
|
+
if (pendingFragments.length === 0) {
|
|
82
|
+
const trailing = processLines(chunk)
|
|
83
|
+
if (trailing !== '') pendingFragments.push(trailing)
|
|
84
|
+
return
|
|
85
|
+
}
|
|
48
86
|
|
|
49
|
-
|
|
50
|
-
|
|
87
|
+
// We have a buffered prefix. If this chunk also has no terminator, append
|
|
88
|
+
// to the buffer without concatenating — that's the O(N²) trap we're
|
|
89
|
+
// avoiding (large single `data:` payload split across many tiny chunks).
|
|
90
|
+
if (chunk.indexOf('\n') === -1 && chunk.indexOf('\r') === -1) {
|
|
91
|
+
pendingFragments.push(chunk)
|
|
92
|
+
return
|
|
51
93
|
}
|
|
52
94
|
|
|
53
|
-
|
|
54
|
-
|
|
95
|
+
// Terminator arrived. Join the accumulated fragments + this chunk once,
|
|
96
|
+
// process, and buffer any new trailing partial line.
|
|
97
|
+
pendingFragments.push(chunk)
|
|
98
|
+
const input = pendingFragments.join('')
|
|
99
|
+
pendingFragments.length = 0
|
|
100
|
+
const trailing = processLines(input)
|
|
101
|
+
if (trailing !== '') pendingFragments.push(trailing)
|
|
55
102
|
}
|
|
56
103
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
104
|
+
/**
|
|
105
|
+
* Splits `chunk` into SSE lines and dispatches each to the appropriate handler.
|
|
106
|
+
* Returns any trailing bytes that did not terminate with a line break, so the
|
|
107
|
+
* caller can prepend them to the next chunk.
|
|
108
|
+
*
|
|
109
|
+
* The SSE spec permits three line terminators: `\n`, `\r`, and `\r\n`. Real-world
|
|
110
|
+
* streams almost always use plain `\n`, so we take a fast path when no `\r` is
|
|
111
|
+
* present in the chunk. The slow path is spec-correct but does more work per line.
|
|
112
|
+
*/
|
|
113
|
+
function processLines(chunk: string): string {
|
|
114
|
+
let searchIndex = 0
|
|
115
|
+
|
|
116
|
+
// Fast path: LF-only chunk (the common case for typical SSE servers).
|
|
117
|
+
// We can scan forward with a single `indexOf('\n')` per line and inline
|
|
118
|
+
// the hot-path branches for `data:` and `event:` without the CR bookkeeping
|
|
119
|
+
// the slow path needs.
|
|
120
|
+
if (chunk.indexOf('\r') === -1) {
|
|
121
|
+
let lfIndex = chunk.indexOf('\n', searchIndex)
|
|
122
|
+
while (lfIndex !== -1) {
|
|
123
|
+
// Blank line: end-of-event marker. Dispatch the accumulated event (if any)
|
|
124
|
+
// and reset the buffered fields. This is hoisted out of `parseLine` because
|
|
125
|
+
// it's the single most common line shape after `data:` lines.
|
|
126
|
+
if (searchIndex === lfIndex) {
|
|
127
|
+
if (dataLines > 0) {
|
|
128
|
+
onEvent({id, event: eventType, data})
|
|
129
|
+
}
|
|
130
|
+
id = undefined
|
|
131
|
+
data = ''
|
|
132
|
+
dataLines = 0
|
|
133
|
+
eventType = undefined
|
|
134
|
+
searchIndex = lfIndex + 1
|
|
135
|
+
lfIndex = chunk.indexOf('\n', searchIndex)
|
|
136
|
+
continue
|
|
137
|
+
}
|
|
138
|
+
const firstCharCode = chunk.charCodeAt(searchIndex)
|
|
139
|
+
if (isDataPrefix(chunk, searchIndex, firstCharCode)) {
|
|
140
|
+
// `data:` line — append the value to the event's data buffer.
|
|
141
|
+
// 'data:'.length === 5, 'data: '.length === 6
|
|
142
|
+
const valueStart =
|
|
143
|
+
chunk.charCodeAt(searchIndex + 5) === SPACE ? searchIndex + 6 : searchIndex + 5
|
|
144
|
+
const value = chunk.slice(valueStart, lfIndex)
|
|
145
|
+
// Fast path within a fast path: if this is the first data line AND the
|
|
146
|
+
// next char is another LF (i.e. `data:foo\n\n`), dispatch immediately
|
|
147
|
+
// without ever writing to the `data` buffer. This is the shape of a
|
|
148
|
+
// typical single-line SSE event (ChatGPT-style streams, etc.) and is
|
|
149
|
+
// hot enough to be worth the duplication.
|
|
150
|
+
if (dataLines === 0 && chunk.charCodeAt(lfIndex + 1) === LF) {
|
|
151
|
+
onEvent({id, event: eventType, data: value})
|
|
152
|
+
id = undefined
|
|
153
|
+
data = ''
|
|
154
|
+
eventType = undefined
|
|
155
|
+
searchIndex = lfIndex + 2
|
|
156
|
+
lfIndex = chunk.indexOf('\n', searchIndex)
|
|
157
|
+
continue
|
|
158
|
+
}
|
|
159
|
+
// Multi-line data: concatenate with newline separator per spec.
|
|
160
|
+
data = dataLines === 0 ? value : `${data}\n${value}`
|
|
161
|
+
dataLines++
|
|
162
|
+
} else if (isEventPrefix(chunk, searchIndex, firstCharCode)) {
|
|
163
|
+
// `event:` line — set the event type for the next dispatch. Per spec,
|
|
164
|
+
// an empty value resets `event type` to its default (undefined here).
|
|
165
|
+
// 'event:'.length === 6, 'event: '.length === 7
|
|
166
|
+
eventType =
|
|
167
|
+
chunk.slice(
|
|
168
|
+
chunk.charCodeAt(searchIndex + 6) === SPACE ? searchIndex + 7 : searchIndex + 6,
|
|
169
|
+
lfIndex,
|
|
170
|
+
) || undefined
|
|
171
|
+
} else {
|
|
172
|
+
// Everything else: `id:`, `retry:`, comment lines (`:` prefix), unknown
|
|
173
|
+
// fields, or malformed lines. These are rarer and go through the full
|
|
174
|
+
// per-line parser, which handles the SSE field grammar in detail.
|
|
175
|
+
parseLine(chunk, searchIndex, lfIndex)
|
|
176
|
+
}
|
|
177
|
+
searchIndex = lfIndex + 1
|
|
178
|
+
lfIndex = chunk.indexOf('\n', searchIndex)
|
|
179
|
+
}
|
|
180
|
+
return chunk.slice(searchIndex)
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
// Slow path: the chunk contains at least one `\r`, so lines may be terminated
|
|
184
|
+
// by `\r`, `\n`, or `\r\n`. We locate the next terminator by looking at both
|
|
185
|
+
// the nearest `\r` and `\n` and picking whichever comes first.
|
|
186
|
+
while (searchIndex < chunk.length) {
|
|
187
|
+
const crIndex = chunk.indexOf('\r', searchIndex)
|
|
188
|
+
const lfIndex = chunk.indexOf('\n', searchIndex)
|
|
189
|
+
|
|
190
|
+
let lineEnd = -1
|
|
191
|
+
if (crIndex !== -1 && lfIndex !== -1) {
|
|
192
|
+
lineEnd = crIndex < lfIndex ? crIndex : lfIndex
|
|
193
|
+
} else if (crIndex !== -1) {
|
|
194
|
+
// A trailing `\r` at the very end of the chunk is ambiguous: it could be
|
|
195
|
+
// a bare-CR terminator, or the first half of a `\r\n` whose `\n` arrives
|
|
196
|
+
// in the next chunk. Defer until we see more input.
|
|
197
|
+
if (crIndex === chunk.length - 1) {
|
|
198
|
+
lineEnd = -1
|
|
199
|
+
} else {
|
|
200
|
+
lineEnd = crIndex
|
|
201
|
+
}
|
|
202
|
+
} else if (lfIndex !== -1) {
|
|
203
|
+
lineEnd = lfIndex
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
if (lineEnd === -1) {
|
|
207
|
+
break
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
parseLine(chunk, searchIndex, lineEnd)
|
|
211
|
+
searchIndex = lineEnd + 1
|
|
212
|
+
// If we just consumed a `\r` and the next char is `\n`, skip it so the
|
|
213
|
+
// pair is treated as a single terminator rather than an empty line.
|
|
214
|
+
if (chunk.charCodeAt(searchIndex - 1) === CR && chunk.charCodeAt(searchIndex) === LF) {
|
|
215
|
+
searchIndex++
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
return chunk.slice(searchIndex)
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
function parseLine(chunk: string, start: number, end: number) {
|
|
223
|
+
if (start === end) {
|
|
60
224
|
dispatchEvent()
|
|
61
225
|
return
|
|
62
226
|
}
|
|
63
227
|
|
|
64
|
-
|
|
65
|
-
|
|
228
|
+
const firstCharCode = chunk.charCodeAt(start)
|
|
229
|
+
|
|
230
|
+
if (isDataPrefix(chunk, start, firstCharCode)) {
|
|
231
|
+
// 'data:'.length === 5, 'data: '.length === 6
|
|
232
|
+
const valueStart = chunk.charCodeAt(start + 5) === SPACE ? start + 6 : start + 5
|
|
233
|
+
const value = chunk.slice(valueStart, end)
|
|
234
|
+
data = dataLines === 0 ? value : `${data}\n${value}`
|
|
235
|
+
dataLines++
|
|
236
|
+
return
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
if (isEventPrefix(chunk, start, firstCharCode)) {
|
|
240
|
+
// 'event:'.length === 6, 'event: '.length === 7
|
|
241
|
+
eventType =
|
|
242
|
+
chunk.slice(chunk.charCodeAt(start + 6) === SPACE ? start + 7 : start + 6, end) || undefined
|
|
243
|
+
return
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
// Fast path for "id:" — 'i' = 105, 'd' = 100, ':' = 58
|
|
247
|
+
if (
|
|
248
|
+
firstCharCode === 105 &&
|
|
249
|
+
chunk.charCodeAt(start + 1) === 100 &&
|
|
250
|
+
chunk.charCodeAt(start + 2) === 58
|
|
251
|
+
) {
|
|
252
|
+
// 'id:'.length === 3, 'id: '.length === 4
|
|
253
|
+
const value = chunk.slice(chunk.charCodeAt(start + 3) === SPACE ? start + 4 : start + 3, end)
|
|
254
|
+
id = value.includes('\0') ? undefined : value
|
|
255
|
+
return
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
// Comment line — ':' = 58
|
|
259
|
+
if (firstCharCode === 58) {
|
|
66
260
|
if (onComment) {
|
|
67
|
-
|
|
261
|
+
const line = chunk.slice(start, end)
|
|
262
|
+
// skip ':' (+1), or ': ' (+2) when a space follows
|
|
263
|
+
onComment(line.slice(chunk.charCodeAt(start + 1) === SPACE ? 2 : 1))
|
|
68
264
|
}
|
|
69
265
|
return
|
|
70
266
|
}
|
|
71
267
|
|
|
72
|
-
|
|
268
|
+
const line = chunk.slice(start, end)
|
|
73
269
|
const fieldSeparatorIndex = line.indexOf(':')
|
|
74
|
-
if (fieldSeparatorIndex
|
|
75
|
-
|
|
76
|
-
// and let `field` be that string.
|
|
77
|
-
const field = line.slice(0, fieldSeparatorIndex)
|
|
78
|
-
|
|
79
|
-
// Collect the characters on the line after the first U+003A COLON character (:),
|
|
80
|
-
// and let `value` be that string. If value starts with a U+0020 SPACE character,
|
|
81
|
-
// remove it from value.
|
|
82
|
-
const offset = line[fieldSeparatorIndex + 1] === ' ' ? 2 : 1
|
|
83
|
-
const value = line.slice(fieldSeparatorIndex + offset)
|
|
84
|
-
|
|
85
|
-
processField(field, value, line)
|
|
270
|
+
if (fieldSeparatorIndex === -1) {
|
|
271
|
+
processField(line, '', line)
|
|
86
272
|
return
|
|
87
273
|
}
|
|
88
274
|
|
|
89
|
-
|
|
90
|
-
//
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
processField(
|
|
275
|
+
const field = line.slice(0, fieldSeparatorIndex)
|
|
276
|
+
// skip ':' (+1), or ': ' (+2) when a space follows
|
|
277
|
+
const offset = line.charCodeAt(fieldSeparatorIndex + 1) === SPACE ? 2 : 1
|
|
278
|
+
const value = line.slice(fieldSeparatorIndex + offset)
|
|
279
|
+
processField(field, value, line)
|
|
94
280
|
}
|
|
95
281
|
|
|
96
282
|
function processField(field: string, value: string, line: string) {
|
|
@@ -98,12 +284,11 @@ export function createParser(callbacks: ParserCallbacks): EventSourceParser {
|
|
|
98
284
|
switch (field) {
|
|
99
285
|
case 'event':
|
|
100
286
|
// Set the `event type` buffer to field value
|
|
101
|
-
eventType = value
|
|
287
|
+
eventType = value || undefined
|
|
102
288
|
break
|
|
103
289
|
case 'data':
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
data = `${data}${value}\n`
|
|
290
|
+
data = dataLines === 0 ? value : `${data}\n${value}`
|
|
291
|
+
dataLines++
|
|
107
292
|
break
|
|
108
293
|
case 'id':
|
|
109
294
|
// If the field value does not contain U+0000 NULL, then set the `ID` buffer to
|
|
@@ -139,94 +324,72 @@ export function createParser(callbacks: ParserCallbacks): EventSourceParser {
|
|
|
139
324
|
}
|
|
140
325
|
|
|
141
326
|
function dispatchEvent() {
|
|
142
|
-
|
|
143
|
-
if (shouldDispatch) {
|
|
327
|
+
if (dataLines > 0) {
|
|
144
328
|
onEvent({
|
|
145
329
|
id,
|
|
146
|
-
event: eventType
|
|
147
|
-
|
|
148
|
-
// then remove the last character from the data buffer.
|
|
149
|
-
data: data.endsWith('\n') ? data.slice(0, -1) : data,
|
|
330
|
+
event: eventType,
|
|
331
|
+
data,
|
|
150
332
|
})
|
|
151
333
|
}
|
|
152
334
|
|
|
153
|
-
// Reset for the next event
|
|
154
335
|
id = undefined
|
|
155
336
|
data = ''
|
|
156
|
-
|
|
337
|
+
dataLines = 0
|
|
338
|
+
eventType = undefined
|
|
157
339
|
}
|
|
158
340
|
|
|
159
341
|
function reset(options: {consume?: boolean} = {}) {
|
|
160
|
-
if (
|
|
161
|
-
|
|
342
|
+
if (options.consume && pendingFragments.length > 0) {
|
|
343
|
+
const incompleteLine = pendingFragments.join('')
|
|
344
|
+
parseLine(incompleteLine, 0, incompleteLine.length)
|
|
162
345
|
}
|
|
163
346
|
|
|
164
347
|
isFirstChunk = true
|
|
165
348
|
id = undefined
|
|
166
349
|
data = ''
|
|
167
|
-
|
|
168
|
-
|
|
350
|
+
dataLines = 0
|
|
351
|
+
eventType = undefined
|
|
352
|
+
pendingFragments.length = 0
|
|
169
353
|
}
|
|
170
354
|
|
|
171
355
|
return {feed, reset}
|
|
172
356
|
}
|
|
173
357
|
|
|
174
358
|
/**
|
|
175
|
-
*
|
|
359
|
+
* Checks if `chunk` starts with the literal `data:` at index `i`.
|
|
176
360
|
*
|
|
177
|
-
*
|
|
178
|
-
*
|
|
179
|
-
*
|
|
361
|
+
* Equivalent to `chunk.startsWith('data:', i)`, but benchmarks show this
|
|
362
|
+
* hand-unrolled char-code comparison is ~20% faster on common event types.
|
|
363
|
+
* The caller passes `firstCharCode` (the code at `i`) so it can be reused
|
|
364
|
+
* across prefix checks.
|
|
365
|
+
*
|
|
366
|
+
* ASCII: 'd' = 100, 'a' = 97, 't' = 116, 'a' = 97, ':' = 58
|
|
180
367
|
*/
|
|
181
|
-
function
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
let searchIndex = 0
|
|
191
|
-
|
|
192
|
-
while (searchIndex < chunk.length) {
|
|
193
|
-
// Find next line terminator
|
|
194
|
-
const crIndex = chunk.indexOf('\r', searchIndex)
|
|
195
|
-
const lfIndex = chunk.indexOf('\n', searchIndex)
|
|
196
|
-
|
|
197
|
-
// Determine line end
|
|
198
|
-
let lineEnd = -1
|
|
199
|
-
if (crIndex !== -1 && lfIndex !== -1) {
|
|
200
|
-
// CRLF case
|
|
201
|
-
lineEnd = Math.min(crIndex, lfIndex)
|
|
202
|
-
} else if (crIndex !== -1) {
|
|
203
|
-
// CR at the end of a chunk might be part of a CRLF sequence that spans chunks,
|
|
204
|
-
// so we shouldn't treat it as a line terminator (yet)
|
|
205
|
-
if (crIndex === chunk.length - 1) {
|
|
206
|
-
lineEnd = -1
|
|
207
|
-
} else {
|
|
208
|
-
lineEnd = crIndex
|
|
209
|
-
}
|
|
210
|
-
} else if (lfIndex !== -1) {
|
|
211
|
-
lineEnd = lfIndex
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
// Extract line if terminator found
|
|
215
|
-
if (lineEnd === -1) {
|
|
216
|
-
// No terminator found, rest is incomplete
|
|
217
|
-
incompleteLine = chunk.slice(searchIndex)
|
|
218
|
-
break
|
|
219
|
-
} else {
|
|
220
|
-
const line = chunk.slice(searchIndex, lineEnd)
|
|
221
|
-
lines.push(line)
|
|
222
|
-
|
|
223
|
-
// Move past line terminator
|
|
224
|
-
searchIndex = lineEnd + 1
|
|
225
|
-
if (chunk[searchIndex - 1] === '\r' && chunk[searchIndex] === '\n') {
|
|
226
|
-
searchIndex++
|
|
227
|
-
}
|
|
228
|
-
}
|
|
229
|
-
}
|
|
368
|
+
function isDataPrefix(chunk: string, i: number, firstCharCode: number): boolean {
|
|
369
|
+
return (
|
|
370
|
+
firstCharCode === 100 &&
|
|
371
|
+
chunk.charCodeAt(i + 1) === 97 &&
|
|
372
|
+
chunk.charCodeAt(i + 2) === 116 &&
|
|
373
|
+
chunk.charCodeAt(i + 3) === 97 &&
|
|
374
|
+
chunk.charCodeAt(i + 4) === 58
|
|
375
|
+
)
|
|
376
|
+
}
|
|
230
377
|
|
|
231
|
-
|
|
378
|
+
/**
|
|
379
|
+
* Checks if `chunk` starts with the literal `event:` at index `i`.
|
|
380
|
+
*
|
|
381
|
+
* See {@link isDataPrefix} for why this is hand-unrolled rather than using
|
|
382
|
+
* `String.prototype.startsWith`.
|
|
383
|
+
*
|
|
384
|
+
* ASCII: 'e' = 101, 'v' = 118, 'e' = 101, 'n' = 110, 't' = 116, ':' = 58
|
|
385
|
+
*/
|
|
386
|
+
function isEventPrefix(chunk: string, i: number, firstCharCode: number): boolean {
|
|
387
|
+
return (
|
|
388
|
+
firstCharCode === 101 &&
|
|
389
|
+
chunk.charCodeAt(i + 1) === 118 &&
|
|
390
|
+
chunk.charCodeAt(i + 2) === 101 &&
|
|
391
|
+
chunk.charCodeAt(i + 3) === 110 &&
|
|
392
|
+
chunk.charCodeAt(i + 4) === 116 &&
|
|
393
|
+
chunk.charCodeAt(i + 5) === 58
|
|
394
|
+
)
|
|
232
395
|
}
|