# sailsjs-socket.io-client

> This is a extended socket.io-client for node, that works with sailjs. It adds the handshake functionality and implements the GET POST PUT DELETE functions from sails socket.io.

Latest version **0.1.2** (published 2014-01-13) · BSD-2-Clause license · 0 weekly downloads

## Install

```sh
npm install sailsjs-socket.io-client
pnpm add sailsjs-socket.io-client
yarn add sailsjs-socket.io-client
bun add sailsjs-socket.io-client
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.2 |
| Published | 2014-01-13 |
| First published | 2014-01-13 |
| Weekly downloads | 0 |
| License | BSD-2-Clause |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Known vulnerabilities | 0 (+3 in 2 direct dependencies) |
| Install scripts | no |
| Author | Steven Wirges |
| Maintainers | stvnwrgs |
| Keywords | sailsjs, sails, socket.io-client, socket.io, socket, handshake |

## Links

- npm: https://www.npmjs.com/package/sailsjs-socket.io-client
- Repository: git@github.com:stvnwrgs/sailsio-node-client
- Homepage: https://github.com/stvnwrgs/sailsio-node-client
- Issues: https://github.com/stvnwrgs/sailsio-node-client/issues
- npm.io page: https://npm.io/package/sailsjs-socket.io-client

## Dependencies (3)

- [request](https://npm.io/package/request.md) ~2.31.0
- [xmlhttprequest](https://npm.io/package/xmlhttprequest.md) ~1.6.0
- [socket.io-client](https://npm.io/package/socket.io-client.md) ~0.9.16

## Recent versions

- 0.1.2 (latest) — 2014-01-13

## README

sailsjs-socket.io-client
===================

 This is a extended socket.io-client for node, that works with sailjs. It adds the handshake functionality and implements the GET POST PUT DELETE functions from sails socket.io.

Example:

```javascript
SailsIo.connect('http://127.0.0.1:1337', function (socket) {

  socket.on('connecting', function() {
    console.log('(II) Connecting to server');
  });
  socket.on('connect', function () {
    console.log('connected');

    socket.on('event', function(data){
      
    });

    socket.on('disconnect', function (reason) {
      console.log('(II) Disconnected from server\n');
    });

    socket.on('reconnect', function(socket){
      console.log(socket);
    });


    socket.on('reconnect_error', function (error) {
      console.log(error);
    })
  });

  socket.on('error', function (reason) {
    console.log('(EE) Error connecting to server: ' + reason);
    process.exit(code=0);
  });

});
```

---
_Source: https://npm.io/package/sailsjs-socket.io-client · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
