mirror of
https://github.com/socketio/socket.io.git
synced 2026-01-07 22:23:57 -05:00
f3e1f5ebdf59158d0c8d1e20f8230275617fb355
The init() method of the adapter will now be called when creating a namespace with `io.of(<the-namespace>)`.
Note: any promise rejection is silently caught, as I don't see how we could properly expose the promise.
```js
const io = new Server({
adapter: myAdapter
});
// under the hood, this:
// - implicitly creates the main namespace (/)
// - creates an instance of `myAdapter` for the main namespace
// - calls `myAdapter.init()` (with this change)
```
Related:
- https://github.com/socketio/socket.io/issues/3662
- https://github.com/socketio/socket.io-postgres-adapter/issues/16
socket.io
Getting Started
Please check our documentation here.
Questions
Our issues list is exclusively reserved for bug reports and feature requests. For usage questions, please use the following resources:
- read our documentation
- check our troubleshooting guide
- look for/ask questions on Stack Overflow
- create a new discussion
Security
If you think that you have found a security vulnerability in our project, please do not create an issue in this GitHub repository, but rather refer to our Security Policy.
Issues and contribution
Please make sure to read our Contributing Guide before creating an issue or making a pull request.
Thanks to everyone who has already contributed to Socket.IO!
License
Languages
TypeScript
64.1%
JavaScript
35.8%