All Projects → Meituan-Dianping → Easyreact

Meituan-Dianping / Easyreact

Licence: apache-2.0
Are you confused by the functors, applicatives, and monads in RxSwift and ReactiveCocoa? It doesn't matter, the concepts are so complicated that not many developers actually use them in normal projects. Is there an easy-to-use way to use reactive programming? EasyReact is born for this reason.

Projects that are alternatives of or similar to Easyreact

Cycle.swift
An experiment in unidirectional architecture inspired by Cycle.js. https://cycle.js.org
Stars: ✭ 24 (-98.51%)
Mutual labels:  reactive, rxswift
Swiftrex
Swift + Redux + (Combine|RxSwift|ReactiveSwift) -> SwiftRex
Stars: ✭ 267 (-83.48%)
Mutual labels:  rxswift, reactivecocoa
mvcvm-swift-file-templates
Swift file templates for boosting mobile app development.
Stars: ✭ 16 (-99.01%)
Mutual labels:  reactive, rxswift
Mp3ID3Tagger
🎶🎵A macOS application to edit the ID3 tag of your mp3 files. Developed with RxSwift and RxCocoa. 🎸🎼
Stars: ✭ 17 (-98.95%)
Mutual labels:  reactive, rxswift
Rxiglistkit
RxSwift wrapper for IGListKit
Stars: ✭ 44 (-97.28%)
Mutual labels:  reactive, rxswift
YoutubeEngine
Swift ReactiveCocoa lib for Youtube api
Stars: ✭ 24 (-98.51%)
Mutual labels:  reactive, reactivecocoa
callbag-rs
Rust implementation of the callbag spec for reactive/iterable programming
Stars: ✭ 25 (-98.45%)
Mutual labels:  reactive, stream
Sensor
A fresh look at iOS development
Stars: ✭ 37 (-97.71%)
Mutual labels:  reactive, rxswift
Rxrealm
RxSwift extension for RealmSwift's types
Stars: ✭ 1,007 (-37.69%)
Mutual labels:  reactive, rxswift
Rxcombine
Bi-directional type bridging between RxSwift and Apple's Combine framework
Stars: ✭ 741 (-54.15%)
Mutual labels:  reactive, rxswift
reactive-rs
Streams and broadcasts: functional reactive programming in Rust.
Stars: ✭ 28 (-98.27%)
Mutual labels:  reactive, stream
Rxviz
Rx Visualizer - Animated playground for Rx Observables
Stars: ✭ 1,471 (-8.97%)
Mutual labels:  reactive, stream
rxjava2-http
Transmit RxJava2 Flowable over http with non-blocking backpressure
Stars: ✭ 19 (-98.82%)
Mutual labels:  reactive, stream
QuickImageFX
Simplifying image manipulation using GDI, Graphics32, OpenCV or Vampyre Imaging libraries
Stars: ✭ 41 (-97.46%)
Mutual labels:  stream, transformations
SwiftObserver
Elegant Reactive Primitives for Clean Swift Architecture #NoRx
Stars: ✭ 14 (-99.13%)
Mutual labels:  reactive, rxswift
futura
Asynchronous Swift made easy. The project was made by Miquido. https://www.miquido.com/
Stars: ✭ 34 (-97.9%)
Mutual labels:  reactive, stream
Moya-Gloss
Gloss bindings for Moya
Stars: ✭ 37 (-97.71%)
Mutual labels:  rxswift, reactivecocoa
mobius-gui
🎨 Reactive & Stream & Driver based UI framework build on Mobius Utils, equipped with neumorphism-derived & utility-first styles.
Stars: ✭ 43 (-97.34%)
Mutual labels:  reactive, stream
Rxswift
Reactive Programming in Swift
Stars: ✭ 21,163 (+1209.59%)
Mutual labels:  reactive, rxswift
Rxswift To Combine Cheatsheet
RxSwift to Apple’s Combine Cheat Sheet
Stars: ✭ 1,040 (-35.64%)
Mutual labels:  reactive, rxswift

EasyReact

Build Status Version License Platform codecov

Read this in other languages: 简体中文

What is EasyReact

EasyReact is an easy-to-use reactive programming framework.

Why use EasyReact

Are you confused by the functors, applicatives, and monads in RxSwift and ReactiveCocoa? It doesn't matter, the concepts are so complicated that not many developers actually use them in normal projects. Is there an easy-to-use way to use reactive programming? EasyReact is born for this reason.

Features

Note: The "Node" listed below refer to EZRNode, a unified representation of various values (all object types) in EasyReact.

Learn more

  1. Framework Overview

  2. Basic Operations

  3. Memory Management

  4. How to Contribute

Compare other Functional Reactive libraries (e.g. ReactiveCocoa or ReactiveX)

Project EasyReact ReactiveCocoa ReactiveX
Core idea Graph theory and object-oriented programming Functional programming Functional programming and generic programming
Propagation variability
Basic transformation
Combination transformation
High-order transformation
Traversal node/signal
Multi-language support Objective-C
(Other language versions will open source in the future)
Objective-C, Swift Many language versions
Performance faster slow fastest
Chinese document support
Debugging tools Topology display
More rich dynamic debugging tools(Coming soon)
Instrument

System Requirements

  • iOS 8.0 +
  • Xcode 8.0 +

How to run the example project

git clone this repo,excute pod install in Example/, then open EasyReact.xcworkspace.

Installation

CocoaPods

Add the following content in Podfile

pod 'EasyReact'

Then execute pod install

How to use (For a more detailed example, please see the test specs in the example project Tests/)

Unit Test

EasyReact contains a complete unit test with the relevant code in the Example/Tests folder. You can open the sample project and execute the Test command to run these unit tests.

Time-consuming Benchmarking with EasyReact and ReactiveCocoa Common APIs

Environment

Build Platform: macOS Mojave 10.14

IDE: Xcode 10.0(10A255)

Device: iPhone XS Max 256G iOS 12.0(16A366)

Cases

  1. Single stage operations, such as listener, map, filter, flattenMap, etc.
  2. Multicast operations, such as combine, zip, merge, etc.
  3. syncWith operations

The scale of the test is based on 10 operating objects and 1000 triggers. For example, the listener method has 10 listeners and repeats the action of sending the value 1000 times. The unit of time is ns.

Result data

Repeat the above experiment 10 times to get the data as follows:

name listener map filter flattenMap combine zip merge syncWith
EasyReact 4218689 26615802 9872381 9896752 5744164 48405085 29639206 11846827
ReactiveCocoa 2263981 42883385 28768289 28810331 127882031 82689281 6809210 30935277
RAC:EasyReact 53.7% 161.1% 291.4% 291.1% 2226.3% 170.8% 23.0% 261.1%

benchmark

Summary

ReactiveCocoa's average time consuming is 434.8% times more than EasyReact.

EasyReact will compare benchmark with RxSwift when the Swift version open source recently.

Authors

William Zang, [email protected]
姜沂, [email protected]
Qin Hong, [email protected]
SketchK, [email protected]
zesming, [email protected]
Zhiyu Wong, [email protected]
johnnywjy, [email protected]
qiezishu, [email protected]

License

EasyReact is Apache Public License 2.0

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].