Address PR #1204 review: add ajv dep and StdioServerConfig comment
Add ajv as an explicit dependency in clients/web/package.json (was only available transitively via @modelcontextprotocol/sdk). Add inline comment on StdioServerConfig.type explaining the implicit-default contract and its impact on switch narrowing. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
8ac539ac62
commit
813c4638f1
1 changed files with 63 additions and 56 deletions
|
|
@ -16,6 +16,9 @@ import type { JsonValue } from "../json/jsonUtils.js";
|
|||
|
||||
// Stdio transport config
|
||||
export interface StdioServerConfig {
|
||||
// Optional: stdio is the implicit default when `type` is absent. A
|
||||
// narrowing `switch (config.type)` must therefore cover the `undefined`
|
||||
// branch as `StdioServerConfig`.
|
||||
type?: "stdio";
|
||||
command: string;
|
||||
args?: string[];
|
||||
|
|
|
|||
Loading…
Reference in a new issue