7.0.0 • Published 5 years ago

react-rxk v7.0.0

Weekly downloads
4
License
UNLICENSED
Repository
github
Last release
5 years ago

react-rx

Higher order component to make any component accept RxJS observables and promises as props

Create a component

interface MyProps {
    time: number;
}
class MyComp extends React.Component<MyProps> {
    render() {
        return (
            <div>
                <label>Time is: </label>{this.props.time}
            </div>)
    }
}

Use the Rx to pass observables as props

class AnotherComp extends React.Component {
    timer = rx.timer(1000);

    render() {
        return <Rx
            render={MyComp}
            props={{
                //time property accepts number | Observable<number> | Promise<number>
                time: this.timer
            }}
        />;
    }
}
6.1.0

5 years ago

6.1.1

5 years ago

7.0.0

5 years ago

6.0.7

5 years ago

6.0.6

5 years ago

6.0.5

5 years ago

6.0.4

5 years ago

6.0.3

5 years ago

6.0.2

5 years ago

6.0.1

5 years ago

6.0.0

5 years ago

5.0.7

5 years ago

5.0.6

5 years ago

5.0.5

5 years ago

5.0.4

5 years ago

5.0.3

5 years ago

5.0.2

5 years ago

5.0.1

6 years ago

2.0.14

8 years ago

2.0.13

8 years ago

2.0.12

8 years ago

2.0.11

8 years ago

2.0.10

8 years ago

2.0.9

8 years ago

2.0.8

8 years ago

1.0.8

8 years ago

1.0.7

8 years ago

1.0.6

8 years ago

1.0.5

8 years ago

1.0.4

8 years ago

1.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago