Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/vitejs/vite
/ onOpen
Function
onOpen
packages/vite/src/client/client.ts:481–484 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
479
const
socket =
new
WebSocket(socketUrl,
'vite-ping'
)
480
return
new
Promise<boolean>((resolve) => {
481
function
onOpen() {
482
resolve(true)
483
close()
484
}
485
function
onError() {
486
resolve(false)
487
close()
Callers
nothing calls this directly
Calls
2
close
Function · 0.70
resolve
Function · 0.50
Tested by
no test coverage detected