Skip to content

Commit 6fb7c43

Browse files
committed
fix: windsurf config, fix #18
1 parent 17d6a50 commit 6fb7c43

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

.vscode/mcp.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@
77
"nuxt-docs": {
88
"type": "sse",
99
"url": "https://mcp.nuxt.com/sse"
10+
},
11+
"vite": {
12+
"type": "sse",
13+
"url": "http://localhost:5200/__mcp/sse"
1014
}
1115
}
1216
}

packages/vite-plugin-mcp/src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,9 +110,9 @@ async function updateConfigs(root: string, sseUrl: string, options: ViteMcpOptio
110110
? JSON.parse(await fs.readFile(windsurfConfigPath, 'utf-8').catch(() => '{}') || '{}')
111111
: {}
112112
config.mcpServers ||= {}
113-
config.mcpServers[updateConfigServerName || 'vite'] = { url: sseUrl }
113+
config.mcpServers[updateConfigServerName || 'vite'] = { serverUrl: sseUrl }
114114
for (const server of updateConfigAdditionalServers) {
115-
config.mcpServers[server.name] = { url: server.url }
115+
config.mcpServers[server.name] = { serverUrl: server.url }
116116
}
117117
await fs.writeFile(windsurfConfigPath, `${JSON.stringify(config, null, 2)}\n`)
118118
// eslint-disable-next-line no-console

0 commit comments

Comments
 (0)