Skip to content

Commit bf149eb

Browse files
Updating documentation
1 parent de5b181 commit bf149eb

File tree

1 file changed

+16
-7
lines changed

1 file changed

+16
-7
lines changed

readme.md

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
jQuery Bindings for the Reactive Extensions for JavaScript
1+
RxJS-jQuery <sup>2.0</sup> - jQuery Bindings for the Reactive Extensions for JavaScript
22
==========================================================
33
## OVERVIEW
44

55
This project provides Reactive Extensions for JavaScript (RxJS) bindings for jQuery to abstract over the event binding, Ajax and Deferreds. The RxJS libraries are not included with this release and must be installed separately.
66

77
## GETTING STARTED
88

9-
There are a number of ways to get started with the jQuery Bindings for RxJS.
9+
There are a number of ways to get started with the jQuery Bindings for RxJS. The files are available on [cdnjs](http://cdnjs.com/) and [jsDelivr](http://www.jsdelivr.com/#!rxjs-jquery).
1010

1111
### Download the Source
1212

@@ -15,6 +15,18 @@ To download the source of the jQuery Bindings for the Reactive Extensions for Ja
1515
git clone https://github.com/Reactive-Extensions/rxjs-jquery.git
1616
cd ./rxjs-jquery
1717

18+
### Installing with [NPM](https://npmjs.org/)
19+
20+
npm install rx-jquery
21+
22+
### Installing with [Bower](http://bower.io/)
23+
24+
bower install rx-jquery
25+
26+
### Installing with [Jam](http://jamjs.org/)
27+
28+
jam install rx-jquery
29+
1830
### Installing with NuGet
1931

2032
PM> Install-Package RxJS-Bridges-jQuery
@@ -89,14 +101,11 @@ Now that we have the throttled input from the textbox, we need to query our serv
89101
});
90102
}
91103

92-
Now that the Wikipedia Search has been wrapped, we can tie together throttled input and our service call. In this case, we will call select on the throttledInput to then take the text from our textInput and then use it to query Wikipedia, filtering out empty records. Finally, to deal with concurrency issues, we'll need to ensure we're getting only the latest value. Issues can arise with asynchronous programming where an earlier value, if not cancelled properly, can be returned before the latest value is returned, thus causing bugs. To ensure that this doesn't happen, we have the [switchLatest](http://msdn.microsoft.com/en-us/library/hh229197\(v=VS.103\).aspx) method which returns only the latest value.
104+
Now that the Wikipedia Search has been wrapped, we can tie together throttled input and our service call. Finally, to deal with concurrency issues, we'll need to ensure we're getting only the latest value. Issues can arise with asynchronous programming where an earlier value, if not cancelled properly, can be returned before the latest value is returned, thus causing bugs. To ensure that this doesn't happen, we have the [switchLatest](http://msdn.microsoft.com/en-us/library/hh229197\(v=VS.103\).aspx) method which returns only the latest value.
93105

94106
var suggestions = throttledInput.select( function (text) {
95107
return searchWikipedia(text);
96108
})
97-
.where( function (data) {
98-
return data.length == 2 && data[1].length > 0;
99-
})
100109
.switchLatest();
101110

102111
Finally, we'll subscribe to our observable by calling subscribe which will receive the results and put them into an unordered list. We'll also handle errors, for example if the server is unavailable by passing in a second function which handles the errors.
@@ -177,7 +186,7 @@ We've only scratched the surface of this library in this simple example.
177186

178187
## LICENSE
179188

180-
Copyright 2011 Microsoft Corporation
189+
Copyright 2013 Microsoft Corporation
181190

182191
Licensed under the Apache License, Version 2.0 (the "License");
183192
you may not use this file except in compliance with the License.

0 commit comments

Comments
 (0)