-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
move streaming sdk to Setup in Readme
- Loading branch information
1 parent
ec68a0d
commit cd14358
Showing
1 changed file
with
22 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,6 +28,28 @@ You can also include it from our CDN-Provider `fastly`. | |
|
||
The Baqend SDK provides a global `DB` variable by default. | ||
|
||
|
||
Baqend Streaming SDK | ||
-------------------- | ||
|
||
If you want to use the realtime streaming queries, you have to either use `baqend-streaming.js` or | ||
`baqend-streaming.min.js` for production. | ||
|
||
In Addition, you can include [Rx.js](https://github.com/ReactiveX/rxjs) v5 into your project, for many advanced | ||
Observable features. | ||
You can use the unpkg CDN: | ||
|
||
```html | ||
<script type="text/javascript" src="//unpkg.com/@reactivex/[email protected]/dist/global/Rx.js"></script> | ||
<!-- include the SDK after rxjs --> | ||
<script type="text/javascript" src="//www.baqend.com/js-sdk/latest/baqend-streaming.js"></script> | ||
``` | ||
|
||
The SDK is shipped with the core-js Observable shim per default. | ||
If you include Rx.js globally, it will be detected and used by the SDK automatically. | ||
You can also set the Observable implementation which the SDK will use, | ||
by setting the `require('baqend/streaming').Observable = Observable` afterwards. | ||
|
||
Initialize | ||
---------- | ||
|
||
|
@@ -60,26 +82,6 @@ DB.ready(function() { | |
</script> | ||
``` | ||
|
||
Baqend Streaming SDK | ||
|
||
If you want to use the realtime streaming queries, you have to either use `baqend-streaming.js` or | ||
`baqend-streaming.min.js` for production. | ||
|
||
In Addition, you can include [Rx.js](https://github.com/ReactiveX/rxjs) v5 into your project, for many advanced | ||
Observable features. | ||
You can use the unpkg CDN: | ||
|
||
```html | ||
<script type="text/javascript" src="//unpkg.com/@reactivex/[email protected]/dist/global/Rx.js"></script> | ||
<!-- include the SDK after rxjs --> | ||
<script type="text/javascript" src="//www.baqend.com/js-sdk/latest/baqend-streaming.js"></script> | ||
``` | ||
|
||
The SDK is shipped with the core-js Observable shim per default. | ||
If you include Rx.js globally, it will be detected and used by the SDK automatically. | ||
You can also set the Observable implementation which the SDK will use, | ||
by setting the `require('baqend/streaming').Observable = Observable` afterwards. | ||
|
||
|
||
Usage in Node.js | ||
---------------- | ||
|