Latest 0.8.0
Homepage https://github.com/iMoya917/IMReactiveTextField
License MIT
Platforms ios 9.0
Dependencies ReactiveCocoa
Frameworks UIKit
Authors

Usage

To run the example project, clone the repo, and run pod install from the Example directory first.

Requirements

Installation

ElunUIElements is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "IMReactiveTextField"

If a compile error occurs, change the varibale value in the Atomic class within the ReactiveSwift pod


internal struct UnsafeAtomicState<State: RawRepresentable>: AtomicStateProtocol where State.RawValue == Int32 {
    internal typealias Transition = (expected: State, next: State)
#if os(macOS) || os(iOS) || os(tvOS) || os(watchOS)
    private let value: UnsafeMutablePointer<Int32>

 ..... 

change for


internal struct UnsafeAtomicState<State: RawRepresentable>: AtomicStateProtocol where State.RawValue == Int32 {
    internal typealias Transition = (expected: State, next: State)
#if os(macOS) || os(iOS) || os(tvOS) || os(watchOS)
    public let value: UnsafeMutablePointer<Int32>

 ..... 

Example

class ViewController: UIViewController {

    @IBOutlet weak var emailTextField: ReactiveValidateTextField!
    @IBOutlet weak var enableButton: UIButton!

    .....

    override func viewDidLoad() {
        super.viewDidLoad()

    let signalEmail = emailTextField.signalReactiveTextField(typeCondition: .JLConditionTypeEmail)

 _ = Signal.combineLatest(signalEmail)
        .map({ (emailCondition) -> Bool in

            return  emailCondition })
        .observeResult({ (response) in
            self.enableButton.isEnabled = response.value!})
        .flatMap { (disponseResult) -> Bool? in
            self.enableButton.isEnabled = disponseResult.isDisposed
            return disponseResult.isDisposed

        }

    ....

}

Author

Iv├ín Moya, [email protected]

License

IMReactiveTextField is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "IMReactiveTextField",
    "version": "0.8.0",
    "summary": "By far the most fantastic view I have seen in my entire life. No joke.",
    "description": "This fantastic view changes its color gradually makes your app look fantastic!",
    "homepage": "https://github.com/iMoya917/IMReactiveTextField",
    "license": "MIT",
    "authors": {
        "Ivan": "[email protected]"
    },
    "source": {
        "git": "https://github.com/iMoya917/IMReactiveTextField.git",
        "tag": "0.8.0"
    },
    "platforms": {
        "ios": "9.0"
    },
    "frameworks": "UIKit",
    "source_files": "IMReactiveTextField/**/*.{swift}",
    "dependencies": {
        "ReactiveCocoa": [
            "5.0"
        ]
    },
    "pushed_with_swift_version": "3.0"
}

Pin It on Pinterest

Share This