Property 'of' does not exist on type 'Socket<DefaultEventsMap, DefaultEventsMap>'.
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 63.2k
- Forks
- 10.3k
- Avg merge
- 11d 20h
- Merged PRs (30d)
- 2
Description
Describe the bug
i can't find the of property to defined a namespace
also cant find socket.to ... to send to specific room >.<
To Reproduce
Socket.IO client version: ^4.7.2
Client
import io from 'socket.io-client';
const socket = io({
transports: ['websocket'],
autoConnect: true,
})
socket.of....
Expected behavior
wanted to have autocomplete on all methods like in the docs .
Platform:
- mac
Additional context
it s about typescript or idk I tried to install @types but same result ....
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by comparing the client Socket API used in the reproduction with the documentation for namespaces and rooms. Check whether of and to are server-side APIs or should be available on the client, then verify the expected TypeScript autocomplete behavior. Done means the supported API is correctly typed or the client/server distinction is documented.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100