You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+8-1
Original file line number
Diff line number
Diff line change
@@ -26,9 +26,16 @@ serve the file `socket.io.js` found in the `dist` folder.
26
26
</script>
27
27
```
28
28
29
+
```js
30
+
// with ES6 import
31
+
importiofrom'socket.io-client';
32
+
33
+
constsocket=io('http://localhost');
34
+
```
35
+
29
36
A slim build (without `JSON3`, a JSON polyfill for IE6/IE7, and `debug`) is also available: `socket.io.slim.js`.
30
37
31
-
Socket.IO is compatible with [browserify](http://browserify.org/).
38
+
Socket.IO is compatible with [browserify](http://browserify.org/) and [webpack](https://webpack.js.org/) (see example [there](https://github.com/socketio/socket.io/tree/2.0.3/examples/webpack-build)).
0 commit comments