Determines whether an observable sequence is empty.
(Observable
): An observable sequence containing a single element determining whether the source sequence is empty.
/* Not empty */
var source = Rx.Observable.range(0, 5)
.isEmpty()
var subscription = source.subscribe(
function (x) {
console.log('Next: ' + x);
},
function (err) {
console.log('Error: ' + err);
},
function () {
console.log('Completed');
});
// => Next: false
// => Completed
/* Empty */
var source = Rx.Observable.empty()
.isEmpty()
var subscription = source.subscribe(
function (x) {
console.log('Next: ' + x);
},
function (err) {
console.log('Error: ' + err);
},
function () {
console.log('Completed');
});
// => Next: true
// => Completed
File:
Dist:
Prerequisites:
NPM Packages:
NuGet Packages:
Unit Tests: