Skip to content

v5.2.0

Compare
Choose a tag to compare
@jondubois jondubois released this 02 Jan 12:39
· 319 commits to master since this release

When using emit, publish, etc... It will clone the input data by default.

Before, if the socket was disconnected and you published/emitted an object (by reference) and then changed it immediately after the function was called, then by the time the connection was re-established, it would emit the modified object instead of the object as it appeared at the time the emit/publish was invoked.

You can set the 'cloneData' option to false (from socketCluster.connect(options)) to turn this off.