npm socket.io-client 4.3.0

latest releases: 4.7.5, 4.7.4, 4.7.3...
2 years ago

An ESM bundle is now provided:

<script type="module">
  import { io } from "https://cdn.socket.io/4.3.0/socket.io.esm.min.js";

  const socket = io();

  socket.emit("hello", "world");
</script>

The bundle size has also been greatly reduced, from 16.0 KB to 12.9 KB (min+gzip).

Features

  • typings: add missing types for some emitter methods (#1502) (a9e5b85)
  • provide an ESM build with and without debug (16b6569)
  • migrate to rollup (0661564)

Links:

Size of the bundles:

min  min+gzip
socket.io.min.js 39.9 KB (-24.6 KB ⬇️) 12.9 KB (-3.1 KB ⬇️)
socket.io.msgpack.min.js 45.1 KB (-25.6 KB ⬇️) 14 KB (-2.6 KB ⬇️)
socket.io.esm.min.js 32.7 KB 11.1 KB

Don't miss a new socket.io-client release

NewReleases is sending notifications on new releases.