- Source:
Members
(static) _endpoint
the ws-endpoint url to connect to
- Source:
(static) db :Minimongo
The Minimongo database implementation we use for this library
Type:
- Minimongo
- Source:
(static) ddp :DDP
The DDP implementation we use for this library
Type:
- Source:
Methods
(static) getUrl() → {string}
Returns the base-url of our connection-endpoint,
having /websocket being stripped
- Source:
Returns:
the connection url
- Type
- string
(static) notify(eventName, optionalDataopt)
Run all callbacks that listen on a given event by name.
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
eventName |
string | ||
optionalData |
object |
<optional> |
- Source:
(static) off(eventName, cb)
Stops listening to a single event on this layer.
Requires **the exact same function** to work properly!
Parameters:
| Name | Type | Description |
|---|---|---|
eventName |
string | |
cb |
function |
- Source:
(static) offChange(cb)
Stops listening the events from `Data.onChange`.
Requires the **exact same callback function** to work properly!
Parameters:
| Name | Type | Description |
|---|---|---|
cb |
function |
- Source:
(static) on(eventName, cb)
Listens to a single event, available on this layer.
Parameters:
| Name | Type | Description |
|---|---|---|
eventName |
string | |
cb |
function |
- Source:
(static) onChange(cb)
Listens to various events of change and pipes them into a single callback.
The events include
- ddp: change
- ddp: connected
- ddp: disconnected
- Accounts: loggingIn
- Accounts: loggingOut
- DB: change
Parameters:
| Name | Type | Description |
|---|---|---|
cb |
function |
- Source:
(static) waitDdpConnected(callback)
Queues a function to be called one time, once ddp connection
is established.
Parameters:
| Name | Type | Description |
|---|---|---|
callback |
function |
- Source:
(static) waitDdpReady(cb)
Runs a callback, once we have our DDP implementation available
Parameters:
| Name | Type | Description |
|---|---|---|
cb |
function |
- Source: