7.0.0 • Published 4 years ago

react-rxk v7.0.0

Weekly downloads
4
License
UNLICENSED
Repository
github
Last release
4 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

4 years ago

6.1.1

4 years ago

7.0.0

4 years ago

6.0.7

4 years ago

6.0.6

4 years ago

6.0.5

4 years ago

6.0.4

4 years ago

6.0.3

4 years ago

6.0.2

4 years ago

6.0.1

4 years ago

6.0.0

4 years ago

5.0.7

4 years ago

5.0.6

4 years ago

5.0.5

4 years ago

5.0.4

4 years ago

5.0.3

4 years ago

5.0.2

4 years ago

5.0.1

5 years ago

2.0.14

6 years ago

2.0.13

6 years ago

2.0.12

6 years ago

2.0.11

6 years ago

2.0.10

6 years ago

2.0.9

6 years ago

2.0.8

6 years ago

1.0.8

7 years ago

1.0.7

7 years ago

1.0.6

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago