All notable changes to this project will be documented in this file.
- Adds
Event
,SingleEvent
,MaybeEvent
andRecorded
conditional conformance toEquatable
where theirElement
is equatable onRXTest
for clients that are using Swift >= 4.1. - Replaces
*.count > 0
with!*.isEmpty
. inAsyncLock, ObserveOn, Zip+Collection, Zip+arity
. - Adds
string
toNSTextView
.
- Fixes issues with CocoaPods and Swift 4.2 version.
- Compatibility with Xcode 10.0
- Adds new
insert
extension to collect and add multiple disposables toDisposeBag
. - Removes string interpolation warning
- Adds
scan(into:accumulator:)
. - Adds
queuePriority
parameter (defaults to.normal
) toOperationQueueScheduler
. - Performance enhancement reduces Bag dispatch inline code size by 12%.
- Adds
customCaptureSubscriptionCallstack
hook to allow custom subscription callstacks to be generated. - Remove usage of
Variable
from Playground, Example projects and Tests. - Add
XCTAssertRecordedElements
toXCTest+Rx
.
- Fix build issues on new arm64_32 architecture (watchOS 5).
- Adds Smart Key Path subscripting to create a binder for property of object.
- Adds
UICollectionView
extensions:prefetchItems
- cancelPrefetchingForItems
- Adds
UITableView
extensions:prefetchRows
cancelPrefetchingForRows
- Fixes various spelling mistakes and missing parameters.
- Adds
UISegmentedControlExtensions
:titleForSegment(at:)
imageForSegment(at:)
- Adds
Maybe.ifEmpty(default:)
operator. - Adds
Maybe.ifEmpty(switchTo:)
operator. - Adds
Maybe.catchErrorJustReturn(_:)
operator. - Add
Single.flatMapMaybe(_:)
operator. - Add
Single.flatMapCompletable(_:)
operator. - Add
Single.zip(_:)
operator. - Add
Single.catchErrorJustReturn(_:)
operator. - Add
Single.asMaybe(_:)
operator. - Add
Single.asCompletable(_:)
operator. - Use
editingEvents
argument incontrolPropertyWithDefaultEvents
.
- Lower macOS Deployment Target to 10.9
- Deprecates
UISegmentedControl.enabled(forSegmentAt:)
in favor ofUISegmentedControl.enabledForSegment(at:)
.
- Adds deprecation warner.
- Fixes ambiguity issue with
Single.do(onNext:onError:onSubscribe:onSubscribed:onDispose:)
andSingle.do(onSuccess:onError:onSubscribe:onSubscribed:onDispose:)
.
- Fixes compilation issue with Xcode 9.1.
- Deprecates
Single.do(onNext:onError:onSubscribe:onSubscribed:onDispose:)
in favor ofSingle.do(onSuccess:onError:onSubscribe:onSubscribed:onDispose:)
.
- Adds
Recorded<Event<T>>
array factory method in RxTest. #1531 - Replaces global functions
next
,error
,completed
withRecorded.next
,Recorded.error
,Recorded.completed
in RxTest. #1510 - Removes
AnyObject
constraint fromDelegate
parameter onDelegateProxy
. #1442 - Adds
ObservableType.bind(to:)
overloads forPublishRelay
andBehaviorRelay
. - Adds
ControlEvent.asSignal()
. - Adds
UISegmentedControl.rx.enabled(forSegmentAt:)
extension. - Adds
UIStepper.rx.stepValue
extension. - Adds error handling Hook to
Single
,Maybe
andCompletable
. #1532 - Adds
recordCallStackOnError
to improve performance ofDEBUG
configuration.
- Changes return value of blocking version of
single
operator fromE?
toE
. #1525 - Removes deprecation attribute from
asSharedSequence
.
- Adds global Hooks and implements error handling hook.
- Deprecates
asSharedSequence
extensions onObservableType
. - Publicly exposes
controlProperty
.
- Changes
Observable
extensions toObservableType
extensions. - Changes
didUpdateFocusInContextWithAnimationCoordinator
UITableView
extension argument toUITableViewFocusUpdateContext
. - Changes access modifier of
DelegateProxy.setForwardToDelegate
toopen
.
- Deprecates
image(transitionType:)
in favor ofimage
. - Changes return type of
ignoreElements
toCompletable
. #1436 - Removes warning of sequence completion from
Binder
. #1431 - Deprecates
Variable
in favor ofBehaviorRelay
.
- Adds
attributedText
toUITextField
. #1249 - Adds
attributedText
toUITextView
. #1249 - Deprecates
shareReplayLatestWhileConnected
andshareReplay
in favor ofshare(replay:scope:)
. #1430 - Changes
publish
,replay
,replayAll
to clear state in case of sequence termination to be more consistent with other Rx implementations and enable retries. #1430 - Replaces
share
with default implementation ofshare(replay:scope:)
. #1430 - Adds
HasDelegate
andHasDataSource
protocols. - Updates package version to v4 format. #1418
- Adds deprecated warnings to API parts that were missing it. #1427
- Improves memory handling in
isScheduleRequiredKey
. #1428 - Removes pre-release identifier from bundle version to enable
TestFlight
submissions. #1424 - Removes code coverage to enable
TestFlight
submissions. #1423 - Fixes Xcode warnings. #1421
- Adds
materialize()
operator for RxBlocking'sBlockingObservable
. #1383 - Adds
first
operator toObservableType
. - Deprecates
UIBindingObserver
in favor ofBinder
. #1411 - Adds another specialization of
SharedSequence
calledSignal
. - Refactors
DelegateProxy
to be type safe. - Changes nested
SharedSequence
strategy to use inner sharing strategy for result.
- Call
controlTextDidChange(…)
as an optional method. #1406 - Fixed issue with
NSControl.rx.value
regarding multiple observers. #1399 - Removes useless extensions from
PrimitiveSequence
. #1248
- Merge of
3.6.1
changes. - Adds
UIScrollView.willEndDragging
extension. #1365 - Adds
enumerated
operator (deprecatesskipWhileWithIndex
,takeWhileWithIndex
,flatMapWithIndex
,mapWithIndex
).
- Fixes gesture recognizer extensions crash. #1382
- Adds
onSubscribed
parameter toSharedSequence
extensions.
- Swift 4.0 compatibility
- Changes delegate proxy to use plugin architecture.
- Fixes public interface leakage of
NSKeyValueObservingOptions
. #1164
- Fixes compilation issue with Xcode 9b3. #1341
- Fixes issues with
andThen
operator. #1347 - Improves locking behavior of
merge
andswitch
operators. #1344
- Adds
timeout
operator toPrimitiveSequence
(Single
,Maybe
,Observable
) - Adds
delay
operator toSharedSequence
. - Adds
andThen
operator toCompleteable
. - Adds
concat
operator toCompleteable
. - Adds
RxPickerViewDataSourceType
- Adds
UIPickerView
extensions:modelSelected
itemTitles
itemAttributedTitles
items
- Adds
UITableView
extensions:modelDeleted
- Adds
UICollectionView
extensions:itemHighlighted
itemUnhighlighted
willDisplayCell
didEndDisplayingCell
willDisplaySupplementaryView
didEndDisplayingSupplementaryView
- Adds
UIScrollView
extensions:willBeginDecelerating
willBeginDragging
willBeginZooming
didEndZooming
- Fixes deadlock anomaly in
shareReplayWhileLatest
. #1323 - Removes duplicated events swallowing in
NSControl
on macOS.
- Adds
from
operator on "SharedSequence" - Adds
concat
operator on "Completable" - Adds
merge
operator on "Completable" - Adds
using
operator on "PrimitiveSequence" - Adds
concatMap
operator. - Adds
share(replay:scope:)
operator. - Adds
multicast(makeSubject:)
operator. - Adds
UIButton.image(for:)
extension. - Adds
UIButton.backgroundImage(for:)
extension. - fixes typos
- Improves reentrancy and synchronization checks.
- Issues with
share()
andshareReplay(_:)
. #1111 .share()
inconsistent in behavior. #1242- Fixes issues with
Driver
sometimes sending initial element async. #1253
3.4.1 (Xcode 8.3.1 / Swift 3.1 compatible)
- Adds
UINavigationController
delegate proxy and extensions:willShow
didShow
- Deprecates
TestScheduler.start(_:create:)
in favor ofTestScheduler.start(disposed:create:)
. - Deprecates
TestScheduler.start(_:subscribed:disposed:create:)
in favor ofTestScheduler.start(created:subscribed:disposed:create:)
.
- Fixes observable sequence completion in case of empty arrays for
combineLatest
andzip
. #1205 - Fixes array version of
merge
operator completing immediately in case one of the observable sequences is empty. #1221 - Adds RxTest to SPM. #1215
- Adds tuple version of operator
SharedSequence.zip
(collection). - Adds tuple version of operator
SharedSequence.zip
. - Adds tuple version of operator
SharedSequence.combineLatest
(collection). - Adds tuple version of operator
SharedSequence.combineLatest
. - Adds missing
trimOutput
parameter toSharedSequence.debug
. - Makes
RxImagePickerDelegateProxy
subclass ofRxNavigationControllerDelegateProxy
.
3.4.0 (Xcode 8.3.1 / Swift 3.1 compatible)
- Xcode 8.3.1 / Swift 3.1 compatibility.
- Add subscription closures for Single, Maybe and Completable (
onSuccess
,onError
,onCompleted
). - Rename Units as Traits and update the documentation for Single, Completable & Maybe.
- Deprecates
bindTo
in favor ofbind(to:)
. - Adds
materialize
operator - Adds
dematerialize
operator - Adds
latest
parameter toSharedSequence.throttle
operator. - Adds
debug
operator toPrimitiveSequence
.
- Fixes problem with
UICollectionView
data source caching and disposal logic. #1154
3.3.1 (Xcode 8 / Swift 3.0 compatible)
- Fixes misspelled
Completeable
toCompletable
. #1134
3.3.0 (Xcode 8 / Swift 3.0 compatible)
- Adds
Single
,Maybe
,Completable
traits inspired by RxJava (operators):create
deferred
just
error
never
delaySubscription
delay
do
filter
map
flatMap
observeOn
subscribeOn
catchError
retry
retryWhen
zip
- Adds
asSingle()
operator onObservableType
. - Adds
asMaybe()
operator onObservableType
. - Adds
asCompletable()
operator onObservableType
. - Adds variadic
combineLatest
andzip
overloads without result selector (defaults to tuple). - Adds array
combineLatest
andzip
overloads with result selector (defaults to array of elements) - Adds optimized synchronous
merge
operator to observable sequence (variadic, array, collection). #579 - Adds optimized synchronous
merge
operator to shared sequence (variadic, array, collection). - Adds
AsyncSubject
implementation. - Adds
XCTAssertEqual
overloads toRxTest
. - Adds
countDownDuration
toUIDatePicker
. - Adds
attributedTitle(for:)
toUIButton
. - Adds
onSubscribed
todo
operator. - Adds
isUserInteractionEnabled
toUIView
.
- Improves DelegateProxy
responds(to:)
selector logic to only respond to used selectors. #1081, #1087 - Deprecates
from()
in favor offrom(optional:)
to avoid issues with implicit conversions to optional. - Fixes thread sanitizer reporting issues with
merge
operator. #1063 - Calls
collectionViewLayout.invalidateLayout()
afterreloadData()
as a workaround for iOS 10 bug. - Changes
UICollectionView.rx.didUpdateFocusInContextWithAnimationCoordinator
context parameter type toUICollectionViewFocusUpdateContext
3.2.0 (Xcode 8 / Swift 3.0 compatible)
- Adds
groupBy
operator - Adds
ifEmpty(switchTo:)
operator - Adds
ifEmpty(default:)
operator - Adds
Disposable
extensiondisposed(by:)
equivalent toaddDisposableTo
that is meant to replace it in future 4.0 version. - Consolidates atomic operations on Linux and Darwin platform.
- Adds DEBUG mode concurrent asserts for
Variable
andObservable.create
. - Adds DEBUG mode concurrent asserts for
Sink
. - Small performance optimizations for subjects.
- Adaptations for Xcode 8.3 beta.
- Adds
numberOfPages
toUIPageControl
. - Adds additional resources cleanup unit tests for cases where operators are used without
DisposeBag
s. - Chroes:
- Adds
final
keyword wherever applicable. - Remove unnecessary
import Foundation
statements. - Examples cleanup.
- Adds
- Improves behavior of
shareReplayWhileConnected
by making sure that events emitted after disconnect are ignored even in case of fast reconnect. - Fixes a couple of operators that were not cleaning up resources on terminal events when used without
DisposeBag
s. - Fixes delegate proxy interaction with subclassing of
UISearchController
. - Fixes delegate proxy interaction with subclassing of
NSTextStorage
. - Fixes delegate proxy interaction with subclassing of
UIWebView
. - Fixes delegate proxy interaction with subclassing of
UIPickerView
.
3.1.0 (Xcode 8 / Swift 3.0 compatible)
- Adds
changed
property toControlProperty
that returnsControlEvent
of user generated changes.textField.text.changed.map { "User changed text to \($0)" }
- Adds optional overloads for
from
operator.let num: Int? = 3; let sequence = Observable.from(num)
- Improves
UIBindingObserver
by tolerating binding from non main dispatch queue. In case binding is attempted from non main dispatch queue it will be automagically dispathed async to main queue. - Makes control property naming consistent for
UIDatePicker
,UISearchBar
,UISegmentedControl
,UISwitch
,UITextField
,UITextView
(value
property + value alias name). - Adds missing extension to
UIScrollView
.didScroll
didZoom
didEndDecelerating
didEndDragging
didScrollToTop
- Renames
refreshing
toisRefreshing
. - adds
UIWebView
extensions:didStartLoad
didFinishLoad
didFailLoad
- Adds
UITabBarController
extensionswillBeginCustomizing
willEndCustomizing
didEndCustomizing
didSelect
- Adds
UIBarButtonItem
extensionstitle
- Performance optimizations
- Improves data source behavior by clearing data source proxy when forwarding delegate is
nil
.
- Fixes anomaly caused by
UITableView
invalid state caching of previous data source even after the change. Binding of reactive data source now triggerslayoutIfNeeded
that invalidates that internal cached state. - Fixes issue with race in
AnyRecursiveScheduler
. #995
3.0.1 (Xcode 8 / Swift 3.0 compatible)
- Fixes RxCocoa problems on macOS (
TextInput
now usesNSTextInputClient
) - Hides accidentally exposed
BagKey
structure. - Makes
notification
extensionname
parameter optional.
3.0.0 (Xcode 8 / Swift 3.0 compatible)
- Prefixes boolean properties with
is
and makesString?
properties consistent.rx.hidden
->rx.isHidden
rx.enabled
->rx.isEnabled
... also ...- since
rx.text
has now typeString?
to be consistent with UIKit, in caseString
is needed there isrx.text.orEmpty
that hasString
type.
- Renames
title(controlState:)
onUIButton
totitle(for:)
. - All data structures are now internal (
Bag
,Queue
,PriorityQueue
...) - Improves performance of
Bag
. - Polishes RxCocoa
URLSession
extensionsJSON
->json
- return type is
Any
instead ofAnyObject
- replaces response tuple parameters, now it's
(HTTPResponse, Data)
- removes name hiding for
request
parameter
- Migrates
Driver
andNSNotification
tests toLinux
. - Removes RxTest from OSX + SPM integration until usable XCTest support on OSX.
- Renames
ObserverType.map
toOberverType.mapObserver
because of possible ambigutites with subjects. - Improves dispatch queue detection logic and replaces concept of threads in favor of dispatch queues (solves a lot of problems on Linux environment).
- Replaces
SectionedViewDataSourceType.model(_:)
withSectionedViewDataSourceType.model(at:)
- Renames
OSX
tomacOS
across the project.
- Fixes wrong casing in
#import "include/_RXObjCRuntime.h"
(was creating issues for people with case sensitive file system). #949 - Fixes issues with locking strategy for subjects. #936
- Fixes code example in comments of RxTableViewExtensions that didn't compile. #947
- Adds
.swift-version
to help package managers to detect Swift 3 version.
3.0.0-rc.1 (Xcode 8 / Swift 3.0 compatible)
- Renames
RxTests
library toRxTest
because of problems with Swift Package Manager. - Adds Swift Package Manager support
- Adds Linux support
- Replaces
AnyObserver
withUIBindingObserver
in public interface. - Renames
resourceCount
toResources.total
. - Makes
rx.text
type consistent with UIKitString?
type.
textField.rx.text // <- now has type `ControlProperty<String?>`
textField.rx.text.orEmpty // <- now has type `ControlProperty<String>`
- Adds optional overloads for
bindTo
anddrive
. Now the following works:
let text: Observable<String> = Observable.just("")
// Previously `map { $0 }` was needed because of mismatch betweeen sequence `String` type and `String?` type
// on binding `rx.text` observer.
text.bindTo(label.rx.text)
.disposed(by: disposeBag)
...
let text = Driver.just("")
text.drive(label.rx.text)
.disposed(by: disposeBag)
- Adds trim output parameter to
debug
operator. #930 - Renames
NSDate
toDate
everywhere. - Renames scheduler init param
globalConcurrentQueueQOS
toqos
and removes custom enum wrapper. - Adds setter to
rx
property to enable mutation of base object.
3.0.0-beta.2 (Xcode 8 / Swift 3.0 compatible)
-
Subscription disposables now only create strong references to sinks until being disposed or sequence terminates. #573
-
Introduces
SharedSequence
and makesDriver
just a specialization ofSharedSequence
. That meansDriver
is now just one specificSharedSequence
and it is now possible to easily create new concepts that have another compile time guarantees in a couple of lines of code. E.g. choosing a background scheduler on which elements are delivered, or choosingshare
as a sharing strategy instead ofshareReplayLatestWhileConnected
. -
Moves
Reactive
struct andReactiveCompatible
fromRxCocoa
toRxSwift
to enable third party consumers to removeRxCocoa
dependency. -
Add
rx.
extensions on Types. -
Moves
UIImagePickerViewController
andCLLocationManager
out ofRxCocoa
toRxExample
project because of App Store submissions issues on iOS 10. -
Adds
sentMessage
got its equivalent sequencemethodInvoked
that produces elements after method is invoked (vs before method is invoked). -
Deprecates
observe
method onDelegateProxy
in favor ofsentMessage
. -
Adds simetric
methodInvoked
method onDelegateProxy
that enables observing after method is invoked. -
Moves all delegate extensions from using
sentMessage
to usingmethodInvoked
(that fixes some problem with editing data sources) -
Fixes problem with
RxTableViewDataSourceProxy
source enabling editing of table view cells (swipe on delete) even if there weren't any observers orforwardToDelegate
wasn't implementingUITableViewDataSource.tableView(_:commit:forRowAt:)
. #907 -
Makes
DelegateProxy
open. #884 -
Deprecates extensions that were polluting Swift collection namespaces and moves them to static functions on
Observable
Observable.combineLatest
Observable.zip
Observable.concat
Observable.catchError
(sequence version)Observable.amb
-
Deprecates extensions that were polluting Swift collection namespaces and moves them to static functions on
Driver
Driver.combineLatest
Driver.zip
Driver.concat
Driver.catchError
(sequence version)Driver.amb
-
Update Getting Started document, section on creating an observable that performs work to Swift 3.0.
-
Removes stale installation instructions.
3.0.0-beta.1 (Xcode 8 GM compatible 8A218a)
- Adapts to new Swift 3.0 syntax.
- Corrects
throttle
operator behavior to be more consistent with other platforms. Addslatest
flag that controls should latest element be emitted after dueTime. - Adds
delay
operator. - Adds
UISearchBar
extensions:bookmarkButtonClicked
resultsListButtonClicked
textDidBeginEditing
textDidEndEditing
- Moves
CLLocationManager
andUIImagePickerViewController
extensions from RxCocoa to RxExample project. #874 - Adds matrix CI builds. =======
3.0.0.alpha.1 (Xcode 8 beta 6 compatible 8S201h)
- Modernizes API to be more consistent with Swift 3.0 API Design Guidelines
- Replaces
rx_*
prefix withrx.*
extensions. (Inspired by.lazy
collections API). We've tried annotate deprecated APIs with@available(*, deprecated, renamed: "new method")
but trivial replacements aren't annotated.rx_text
->rx.text
rx_tap
->rx.tap
rx_date
->rx.date
- ...
- Deprecates
subscribeNext
,subscribeError
,subscribeCompleted
in favor ofsubscribe(onNext:onError:onCompleted:onDisposed)
(The downsides of old extensions were inconsistencies with Swift API guidelines. They also weren't expressing that calling them actually performes additional subscriptions and thus potentially additional work beside just registering observers). - Deprecates
doOnNext
,doOnCompleted
,doOnError
in favor ofdo(onNext:onCompleted:onError:onSubscribe:onDisposed:)
- Adds
onSubscribe
andonDisposed
todo
operator. - Adds namespace for immutable disposables called
Disposables
- Deprecates
AnonymousDisposable
in favor ofDisposables.create(with:)
- Deprecates
NopDisposable
in favor ofDisposables.create()
- Deprecates
BinaryDisposable
in favor ofDisposables.create(_:_:)
- Deprecates
- Deprecates
toObservable
in favor ofObservable.from()
. - Replaces old javascript automation tests with Swift UI Tests.
- ...
- There is a problem using
UISwitch
extensions because it seems that a bug exists in UIKit that causes allUISwitch
instances to leak. ReactiveX#842
- Adds Swift 2.3 compatibility.
- Adds
UIViewController.rx_title
extension. - Adds
UIScrollView.rx_scrollEnabled
extension. - Resolve static analysis issues relating to non-use of an assigned value, and potential null dereferences in RxCocoa's Objective-C classes.
- Changes
forwardDelegate
property type onDelegateProxy
fromassign
toweak
. - Simplifies UITable/CollectionView data source generic parameters.
- Adds simple usage examples to UITable/CollectionView data source extensions.
- Documents UITable/CollectionView data source extensions memory management and adds unit tests to cover that documentation.
- Adds
.jazzy.yml
- Adds
UITabBar
extensions and delegate proxy wrapper- rx_didSelectItem
- rx_willBeginCustomizing
- rx_didBeginCustomizing
- rx_willEndCustomizing
- rx_didEndCustomizing
- Adds
UIPickerView
delegate proxy and extensions:- rx_itemSelected
- Adds
UIAlertAction.rx_enabled
extension. - Adds
UIButton.rx_title(controlState: UIControlState = .Normal)
extension. - Adds
UIPageControl.rx_currentPage
extension. - Adds
hasObservers
property to*Subject
.
- Fixes problem with UITable/CollectionView releasing of data sources when result subscription disposable wasn't retained.
- Fixes all Xcode analyzer warnings
- Exposes
installForwardDelegate
. - Adds
proxyForObject
as protocol extension and deprecates global function version. - Improves
installForwardDelegate
assert messaging. - Improves gesture recognizer extensions to use typed gesture recognizers in
rx_event
. - Adds
RxTextInput
protocol to enable creating reactive extensions forUITextInput/NSTextInput
. - Adds
rx_willDisplayCell
andrx_didEndDisplayingCell
extensions toUITableView
. - Improves playgrounds.
- Fixes in documentation.
- Turns off Bitcode for
RxTests
CocoaPods integration. - Fixes
UITextField.rx_text
andUITextView.rx_text
integrations to be more robust when used with two way binding. - Fixes two way binding example code so it now properly handles IME used in Asian cultures and adds explanations how to properly perform two way bindings. ReactiveX#649
- Removes
distinctUntilChanged
from control extensions. ReactiveX#626
- adds
Driver.drive
withVariable
parameter. - exposes
RxSearchBarDelegateProxy
- adds
rx_cancelButtonClicked
toUISearchBar
. - adds
rx_searchButtonClicked
toUISearchBar
. - adds
UISearchController
extensions:rx_didDismiss
rx_didPresent
rx_present
rx_willDismiss
rx_willPresent
- Fixes anomaly with
multicast
disposing subscription. - Small grammar fixes in code.
- Fixes in documentation.
- Xcode 7.3 / Swift 2.2 support
- Adds
rx_badgeValue
toUITabBarItem
. - Adds
rx_progress
toUIProgresView
. - Adds
rx_selectedScopeButtonIndex
toUISearchBar
. - Adds
asyncInstance
toMainScheduler
. - Makes
name
parmeter optional forrx_notification
extension. - Adds
UnitTests.md
. - Adds
Tips.md
. - Updates playground inline documentation with running instructions.
- Synchronizes copy of
RxDataSources
source files inside example project to0.6
release.
- Fixes anomaly with synchronization in disposable setter of
SingleAssignmentDisposable
. - Improves
DelegateProxy
memory management. - Fixes anomaly during two way binding of
UITextView
text value. - Improves
single
operator so it handles reentrancy better.
- Fixes problem with
timer
operator. Changes return type fromObservable<Int64>
toObservable<T>
. This could potentially cause code breakage, but it was an API anomaly. - Curried functions were marked deprecated so they were replaced in
UITableView
andUICollectionView
extensions with equivalent lambdas. This shouldn't break anyone's code, but it is a change in public interface.
This is example of those changes:
- public func rx_itemsWithCellFactory<S : Sequence, O : ObservableType where O.E == S>
(source: O)
(cellFactory: (UITableView, Int, S.Iterator.Element) -> UITableViewCell) -> Disposable
+ public func rx_itemsWithCellFactory<S : Sequence, O : ObservableType where O.E == S>
(source: O)
-> (cellFactory: (UITableView, Int, S.Iterator.Element) -> UITableViewCell) -> Disposable
- Fixes anomaly in
CLLocationManager
extensions
- public var rx_didFinishDeferredUpdatesWithError: RxSwift.Observable<NSError> { get }
+ public var rx_didFinishDeferredUpdatesWithError: RxSwift.Observable<NSError?> { get }
- Adds
UIBindingObserver
. - Adds
doOnNext
convenience operator (also added toDriver
). - Adds
doOnError
convenience operator. - Adds
doOnCompleted
convenience operator (also added toDriver
). - Adds
skip
,startWith
toDriver
. - Adds
rx_active
extension toNSLayoutConstraint
. - Adds
rx_refreshing
extension toUIRefreshControl
. - Adds
interval
andtimer
toDriver
. - Adds
rx_itemAccessoryButtonTapped
toUITableView
extensions. - Adds
rx_networkActivityIndicatorVisible
toUIApplication
. - Adds
rx_selected
toUIControl
.
- Fixes anomaly with registering multiple observers to
UIBarButtonItem
. - Fixes anomaly with blocking operators possibly over-stopping the
RunLoop
.
- Adds
UIImagePickerController
delegate wrappers. - Adds
SectionedViewDataSourceType
that enables third party data sources to use existingrx_modelSelected
/rx_modelDeselected
wrappers. - Adds
rx_modelDeselected
toUITableView
- Adds
rx_itemDeselected
toUITableView
- Adds
rx_modelDeselected
toUICollectionView
- Adds
rx_itemDeselected
toUICollectionView
- Adds
rx_state
toNSButton
- Adds
rx_enabled
toNSControl
- Adds
UIImagePickerController
usage example to Example app.
- Removes usage of
OSSpinLock
s from allDarwin
platforms because of problems with inversion of priority on iOS. Original thread on swift mailing list is here - Reduces verbose output from
RxCocoa
project in debug mode.TRACE_RESOURCES
is now also treated as a verbosity level setting. It is possible to get old output by usingTRACE_RESOURCES
with verbosity level>= 2
. #397 - Fixes anomaly with logging of HTTP body of requests in
RxCocoa
project.
- Changes package names to
io.rx.[library]
- Packages data sources from
RxDataSourceStarterKit
into it's own repository RxDataSources underRxSwiftCommunity
. - Removes deprecated APIs.
- Replaces hacky code that solved anomaly caused by interaction between autocorrect and text controls notification mechanism with proper solution. #333
- Adds generic
public func rx_sentMessage(selector: Selector) -> Observable<[AnyObject]>
that enables observing of messages sent to any object. (This is enabled if DISABLE_SWIZZLING isn't set).- use cases like
cell.rx_sentMessage("prepareForReuse")
are now supported.
- use cases like
- Linux support (proof of concept, but single threaded mode works)
- more info in Documentation/Linux.md
- Initial support for
Swift Package Manager
- works on
Linux
(RxSwift
,RxBlocking
,RxTests
) - doesn't work on OSX because it can't compile
RxCocoa
andRxTests
(because of inclusion ofXCTest
extensions), but OSX has two other package managers and manual method. - Project content is linked to
Sources
automagically using custom tool - more info in Documentation/Linux.md
- works on
- Adds
VirtualTimeScheduler
toRxSwift
- Adds
HistoricalScheduler
toRxSwift
- Improves performance of virtual schedulers using priority queue.
- Adds new
RxTests
library to enable testing of custom Rx operators. This library contains everything needed to write unit tests in the following way:
func testMap() {
let scheduler = TestScheduler(initialClock: 0)
let xs = scheduler.createHotObservable([
next(150, 1),
next(210, 0),
next(220, 1),
next(230, 2),
next(240, 4),
completed(300)
])
let res = scheduler.start { xs.map { $0 * 2 } }
let correctEvents = [
next(210, 0 * 2),
next(220, 1 * 2),
next(230, 2 * 2),
next(240, 4 * 2),
completed(300)
]
let correctSubscriptions = [
Subscription(200, 300)
]
XCTAssertEqual(res.events, correctEvents)
XCTAssertEqual(xs.subscriptions, correctSubscriptions)
}
- Adds test project for
RxExample-iOS
that demonstrates how to easily write marble tests usingRxTests
project.
let (
usernameEvents,
passwordEvents,
repeatedPasswordEvents,
loginTapEvents,
expectedValidatedUsernameEvents,
expectedSignupEnabledEvents
) = (
scheduler.parseEventsAndTimes("e---u1----u2-----u3-----------------", values: stringValues).first!,
scheduler.parseEventsAndTimes("e----------------------p1-----------", values: stringValues).first!,
scheduler.parseEventsAndTimes("e---------------------------p2---p1-", values: stringValues).first!,
scheduler.parseEventsAndTimes("------------------------------------", values: events).first!,
scheduler.parseEventsAndTimes("e---v--f--v--f---v--o----------------", values: validations).first!,
scheduler.parseEventsAndTimes("f--------------------------------t---", values: booleans).first!
)
- Adds example app for GitHub signup example that shows the same example written with and without
Driver
. - Documents idea behind units and
Driver
inUnits.md
. - Example of table view with editing is polished to use more functional approach.
- Adds
deferred
toDriver
unit. - Removes implicitly unwrapped optionals from
CLLocationManager
extensions. - Removes implicitly unwrapped optionals from
NSURLSession
extensions. - Polishes the
debug
operator format. - Adds optional
cellType
parameter to Table/Collection viewrx_itemsWithCellIdentifier
method. - Polish for calculator example in
RxExample
app. - Documents and adds unit tests for tail recursive optimizations of
concat
operator. - Moves
Event
equality operator toRxTests
project. - Adds
seealso
references toreactivex.io
. - Polishes headers in source files and adds tests to enforce standard header format.
- Adds
driveOnScheduler
to enable scheduler mocking forDriver
during unit tests. - Adds assertions to
drive*
family of functions that makes sure they are always called from main thread. - Refactoring and polishing of internal ObjC runtime interception architecture.
-
Changes
ConnectableObservable
, generic argument is now type of elements in observable sequence and not type of underlying subject. (BREAKING CHANGE) -
Removes
RxBox
andRxMutable
box from public interface. (BREAKING CHANGE) -
SchedulerType
now isn't parametrized onTime
andTimeInterval
. -
Deprecates
Variable
implementingObservableType
in favor ofasObservable()
.- Now variable also sends
.Completed
to observable sequence returned fromasObservable
when deallocated. If you were (mis)using variable to return single value... you can just useVariable(1).map { x in ... }
just
operatorObservable.just(1).map { x in ... }
- Now variable also sends
-
Deprecates free functions in favor of
Observable
factory methods, and deprecates versions of operators with hidden external parameters (scheduler, count) in favor of ones with explicit parameter names. E.g.Observable.just(1)
instead ofjust(1)
Observable.empty()
instead ofempty()
Observable.error()
instead offailWith()
Observable.of(1, 2, 3)
instead ofsequenceOf(1, 2, 3)
.debounce(0.2, scheduler: MainScheduler.sharedInstance)
instead of.debounce(0.2, MainScheduler.sharedInstance)
Observable.range(start:0, count: 10)
instead ofrange(0, 10)
Observable.generate(initialState: 0, condition: { $0 < 10 }) { $0 + 1 }
instead ofgenerate(0, condition: { $0 < 10 }) { $0 + 1 }
Observable<Int>.interval(1, scheduler: MainScheduler.sharedInstance)
instead ofinterval(1, MainScheduler.sharedInstance)
...
If you want to continue using free functions form, you can define your free function aliases for
Observable
factory methods (basically copy deprecated methods). -
Deprecates
UIAlertView
extensions.- These extensions could be stored locally if needed.
-
Deprecates
UIActionSheet
extensions.- These extensions could be stored locally if needed.
-
Deprecates
rx_controlEvents
in favor ofrx_controlEvent
. -
Deprecates
MainScheduler.sharedInstance
in favor ofMainScheduler.instance
-
Deprecates
ConcurrentMainScheduler.sharedInstance
in favor ofConcurrentMainScheduler.instance
-
Deprecates factory methods from
Drive
in favor ofDriver
factory methods. -
Deprecates
sampleLatest
in favor ofwithLatestFrom
. -
Deprecates
ScopedDisposable
andscopedDispose()
in favor ofDisposeBag
.
- Improves and documents resource leak code in
RxExample
. - Replaces
unowned
reference withweak
references inRxCocoa
project. - Fixes
debug
operator not using__FILE__
and__LINE__
properly. - Fixes anomaly with
timeout
operator. - Fixes problem with spell-checker and
UIText*
losing focus.
- Adds
ignoreElements
operator. - Adds
timeout
operator (2 overloads). - Adds
shareReplayLatestWhileConnected
operator. - Changes
Driver
to internally useshareReplayLatestWhileConnected
for subscription sharing instead ofshareReplay(1)
. - Adds
flatMapFirst
toDriver
unit. - Adds
replayAll
operator. - Adds
createUnbounded
factory method toReplaySubject
. - Adds optional type hints to
empty
,failWith
andnever
(empty(Int)
now works and means empty observable sequence ofInt
s). - Adds
rx_hidden
toUIView
. - Adds
rx_alpha
toUIView
. - Adds
rx_attributedText
toUILabel
. - Adds
rx_animating
toUIActivityIndicatorView
. - Adds
rx_constant
toNSLayoutConstraint
. - Removes implicitly unwrapped optional from
NSURLSession.rx_response
. - Exposes
rx_createDataSourceProxy
,rx_createDelegateProxy
onUITableView
/UICollectionView
. - Exposes
rx_createDelegateProxy
onUITextView
. - Exposes
rx_createDelegateProxy
onUIScrollView
. - Exposes
RxCollectionViewDataSourceProxy
. - Exposes
RxCollectionViewDelegateProxy
. - Exposes
RxScrollViewDelegateProxy
. - Exposes
RxTableViewDataSourceProxy
. - Exposes
RxTableViewDelegateProxy
. - Deprecates
proxyForObject
in favor ofproxyForObject<P : DelegateProxyType>(type: P.Type, _ object: AnyObject) -> P
. - Deprecates
rx_modelSelected<T>()
in favor ofrx_modelSelected<T>(modelType: T.Type)
. - Adds
func bindTo(variable: Variable<E>) -> Disposable
extension toObservableType
. - Exposes
ControlEvent
init. - Exposes
ControlProperty
init. - Refactoring of example app
- Divides examples into sections
- Adds really simple examples of how to do simple calculated bindings with vanilla Rx.
- Adds really simple examples of table view extensions (sectioned and non sectioned version).
- Refactoring of
GitHub sign in example
to use MVVM paradigm.
- Fixes documentation for
flatMapFirst
- Fixes problem with delegate proxies not detecting all delegate methods in delegate proxy hierarchy.
- Improves KVO mechanism.
- Type of observed object is now first argument
view.rx_observe(CGRect.self, "frame")
- Support for observing ObjC bridged enums and
RawRepresentable
protocol - Support for easier extending of KVO using
KVORepresentable
protocol - Deprecates KVO extensions that don't accept type as first argument in favor of ones that do.
- Type of observed object is now first argument
- Adds
flatMapLatest
(also added toDriver
unit). - Adds
flatMapFirst
operator (also added toDriver
unit). - Adds
retryWhen
operator. - Adds
window
operator. - Adds
single
operator. - Adds
single
(blocking version) operator. - Adds
rx_primaryAction
onUIButton
fortvOS
. - Transforms error types in
RxSwift
/RxCocoa
projects fromNSError
s to Swift enum types.RxError
RxCocoaError
RxCocoaURLError
- ...
NSURLSession
extensions now returnObservable<(NSData!, NSHTTPURLResponse)>
instead ofObservable<(NSData!, NSURLResponse!)>
.- Optimizes consecutive map operators. For example
map(validate1).map(validate2).map(parse)
is now internally optimized to onemap
operator. - Adds overloads for
just
,sequenceOf
,toObservable
that accept scheduler. - Deprecates
asObservable
extension ofSequence
in favor oftoObservable
. - Adds
toObservable
extension toArray
. - Improves table view animated data source example.
- Polishing of
RxDataSourceStarterKit
differentiateForSectionedView
operatorrx_itemsAnimatedWithDataSource
extension
- Makes blocking operators run current thread's runloop while blocking and thus disabling deadlocks.
- Fixes example with
Variable
in playgrounds so it less confusing regarding memory management. - Fixes
UIImageView
extensions to useUIImage?
instead ofUIImage!
. - Fixes improper usage of
CustomStringConvertible
and replaces it withCustomDebugStringConvertible
.
- Optimizations. System now performs significantly fewer allocations and is several times faster then 2.0.0-beta.1
- Makes
AnonymousObservable
private in favor ofcreate
method. - Adds
toArray
operator (non blocking version). - Adds
withLatestFrom
operator, and also extendsDriver
with that operation. - Adds
elementAt
operator (non blocking version). - Adds
takeLast
operator. - Improves
RxExample
app. Adds retries example when network becomes available again. - Adds composite extensions to
Bag
(on
,disposeAllIn
). - Renames mistyped extension on
ObserverType
fromonComplete
toonCompleted
.
- Fixes minimal platform version in OSX version of library to 10.9
- Adds
Driver
unit. This unit uses Swift compiler to prove certain properties about observable sequences. Specifically- that fallback error handling is put in place
- results are observed on main thread
- work is performed only when there is a need (at least one subscriber)
- computation results are shared between different observers (replay latest element)
- Renames
ObserverOf
toAnyObserver
. - Adds new interface
ObservableConvertibleType
. - Adds
BlockingObservable
toRxBlocking
and makes it more consistent withRxJava
. - Renames
func subscribe(next:error:completed:disposed:)
tofunc subscribe(onNext:onError:onCompleted:onDisposed:)
- Adds concat convenience method
public func concat<O : ObservableConvertibleType where O.E == E>(second: O) -> RxSwift.Observable<Self.E>
- Adds
skipUntil
operator. - Adds
takeWhile
operator. - Renames
takeWhile
indexed version totakeWhileWithIndex
- Adds
skipWhile
operator. - Adds
skipWhileWithIndex
operator. - Adds
using
operator. - Renames
func doOn(next:error:completed:)
tofunc doOn(onNext:onError:onCompleted:)
. - Makes
RecursiveImmediateSchedulerOf
private. - Makes
RecursiveSchedulerOf
private. - Adds
ConcurrentMainScheduler
. - Adds overflow error so now in case of overflow, operators will return
RxErrorCode.Overflow
. - Adds
rx_modelAtIndexPath
toUITableView
andUICollectionView
. - Adds
var rx_didUpdateFocusInContextWithAnimationCoordinator: ControlEvent<(context:animationCoordinator:)>
toUITableView
andUICollectionView
- Makes
resultSelector
argument incombineLatest
explicitfunc combineLatest<O1, O2, R>(source1: O1, _ source2: O2, resultSelector: (O1.E, O2.E) throws -> R) -> RxSwift.Observable<R>
. - Makes
resultSelector
argument inzip
explicitfunc combineLatest<O1, O2, R>(source1: O1, _ source2: O2, resultSelector: (O1.E, O2.E) throws -> R) -> RxSwift.Observable<R>
. - Adds activity indicator example in
RxExample
app. - Adds two way binding example in
RxExample
app. - many other small features
- Problem with xcodebuild 7.0.1 treating tvOS shared schemes as osx schemes.
- Adds
tvOS
support - Adds
watchOS
support - Adds auto loading example to example app
- Restores old
Variable
behavior. Variable doesn't send anything on dealloc. - Adds performance tests target.
- Adds more detailed resource tracing during unit tests (important for further optimizations).
- Adds
UIStepper
extensions. - Adds
UIBarButtonItem
enabled property wrapper. - Adds response data to userInfo of error for
rx_response
extensions ofNSURLSession
. - Adds
onNext
,onError
andonCompleted
convenience methods toObserverType
.
- Fixes problem on some systems with unregistering
CurrentThreadScheduler
from current thread. - Fixes retry parameter naming (
maxAttemptCount
). - Fixes a lot of unit test warnings.
- Removes embedding of Swift library with built frameworks.
- Renames
ImmediateScheduler
protocol toImmediateSchedulerType
- Renames
Scheduler
protocol toSchedulerType
- Adds
CurrentThreadScheduler
- Adds
generate
operator - Cleanup of dead observer code.
- Removes
SpinLock
s in disposables in favor of more performantOSAtomicCompareAndSwap32
. - Adds
buffer
operator (version with time and count). - Adds
range
operator. - Adds
repeat
operator.
- Renames
ScopedDispose
toScopedDisposable
- Deprecates
observeSingleOn
in favor ofobserveOn
- Adds inline documentation
- Renames
from
toasObservable
extension method onSequence
- Renames
catchErrorResumeNext
in favor ofcatchErrorJustReturn
- Deprecates
catchErrorToResult
, the preferred way is to use Swiftdo/try/catch
mechanism. - Deprecates
RxResult
, the preferred way is to use Swiftdo/try/catch
mechanism. - Deprecates
sendNext
onVariable
in favor of just usingvalue
setter. - Renames
rx_searchText
torx_text
onUISearchBar+Rx
. - Changes parameter type for
rx_imageAnimated
to be transitionType (kCATransitionFade, kCATransitionMoveIn, ...).
- Problem in RxExample with missing
observeOn
for images.
- Removes deprecated APIs
- Adds
ObservableType
- Moved from using
>-
operator to protocol extensions - Change from
disposeBag.addDisposable
todisposable.addDisposableTo
- Changes in RxCocoa extensions to enable fluent style
- Rename of
do*
todoOn*
- Deprecates
returnElement
in favor ofjust
- Deprecates
aggregate
in favor ofreduce
- Deprecates
variable
in favor ofshareReplay(1)
(to be consistent with RxJS version) - Method
next
onVariable
in favor ofsendNext
- Adds Calculator example app
- Performance improvements for Queue
- Crash in
rx_didChangeAuthorizationStatus
. #89