Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Rx Visualizer - Animated playground for Rx Observables

License

NotificationsYou must be signed in to change notification settings

moroshko/rxviz

Repository files navigation

RxViz logo

Project Status

Looking for maintainers!

Unfortunately, I don't have the time to maintain this project anymore. If you are interested to help, please reach out to me on Twitter@moroshko.

Description

RxViz simply visualizes a given Observable. Your JavaScript code will be evaluated, and, if the last expression is an Observable, a nice animated visualization will appear.

You can also:

  • Control the speed of the animation by modifying theTime window input.
  • Copy the resulting SVG to include in your next Rx presentation.
  • Share the visualization with your friends.

Examples

Basic interval

rxviz-basic-interval

Random error

rxviz-random-error

Higher order Observable

rxviz-higher-order-observable

Pause and resume

rxviz-pause-and-resume

How does it work?

RxViz treats the evaluated Observable as a black box. We rely only on the fact that Observable emits values over time.RxViz doesn't rely on the internals of RxJS. This will allow us to visualizeTC39 Observables in the future.

Technically, we subscribe to the given Observable, and, once a value is observed, we simply add it to the visualization. It's that simple!

How about higher order Observables?

No different. Since a higher order Observable is simply an Observable whose values are Observables themselves, we just repeat the process recursively.

When an Observable value is seen, we subscribe to it. At this point, we create a new "branch" in the visualization.

Thanks

Running locally

npm installnpm run dev

About

Rx Visualizer - Animated playground for Rx Observables

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Contributors5


[8]ページ先頭

©2009-2025 Movatter.jp