This PR adds support for 'streamable HTTP' MCP servers. This is
backwards-compatible with existing SSE servers. We'll first try to
initialize the server in streamable HTTP mode, and then fall back to
legacy SSE if that fails.
This PR also adds our own small SSE parser, `eventsource` was too high
level to do what we need to do.
Refs https://github.com/microsoft/vscode/issues/244751
* mcp: support sse
Didn't seem like Claude Desktop configs have SSE support yet, but I did
the obvious of having an object with a `url`. I also added a `type`
(optional for stdio) so we can better disambiguate types of configs.
Example .vscode/mcp.json:
```
{
"servers": {
"everything": {
"type": "sse",
"url": "http://localhost:3001/sse"
}
}
}
```
Closes#243242
* update layer check
Adds new eslint rule which requires `export` be used for public api types
The `export` is not actually needed, but our existing typing files largely use it. This makes it consistent
Pedantic but we mostly use `Array<x | y>` for arrays of unions instead of `(x | y)[]`. Just adding an eslint rule and updating some places to be consistent