diff --git a/docs/reference/websockets/sails.io.js/sails.io.js.md b/docs/reference/websockets/sails.io.js/sails.io.js.md index 7e0f697a1..b140386a4 100644 --- a/docs/reference/websockets/sails.io.js/sails.io.js.md +++ b/docs/reference/websockets/sails.io.js/sails.io.js.md @@ -14,7 +14,7 @@ The main responsibility of `sails.io.js` is to provide a familiar, Ajax-like int ### Basic usage (browser) -In the browser, all that is required to use `sails.io.js` is to include the library in a ` + ``` and then use `io.socket` as a global variable in subsequent inline or external scripts. For detailed instructions and examples of everyday usage, see [`io.socket`](https://sailsjs.com/documentation/reference/web-sockets/socket-client/io-socket). @@ -56,7 +56,7 @@ There are two ways to configure Sails' socket client in the browser: using HTML The easiest way to configure the four most common settings for the socket client (`autoConnect`, `environment`, `headers`, and `url`) is by sticking one or more HTML attributes on the script tag: ```html - + @@ -120,7 +120,7 @@ Yes. The Sails socket client can be used to great effect with any front-end fra No. The Sails socket client is extremely helpful when building realtime/chat features in a browser-based UI, but like the rest of the `assets/` directory, it is probably not particularly useful if you are building a [native Android app](https://stackoverflow.com/questions/25081188/sending-socket-request-from-client-ios-android-to-sails-js-server/25081189#25081189) or an API with no user interface at all. -Fortunately, like every other boilerplate file and folder in Sails, the socket client is completely optional. To remove it, just delete `assets/js/dependencies/sails.io.js`. +Fortunately, like every other boilerplate file and folder in Sails, the socket client is completely optional. To remove it, just delete `assets/dependencies/sails.io.js`. ##### How does this work? @@ -132,7 +132,7 @@ Under the hood, the socket client (`sails.io.js`) emits Socket.IO messages with By default, a socket connection will be linked to the current browser session (if any) using the `cookie` header that is sent with the initial socket handshake. In order to turn off this behavior, add `nosession=true` to the [`query` property](https://sailsjs.com/documentation/reference/web-sockets/socket-client/sails-socket/properties#?advanced-properties) of the socket before it connects. For example: ``` - + ```