Skip to content

brentwilton/rxjs-break

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

rxjs-break

RxJS operator breakpoint library

GitHub License NPM version Downloads

What is it?

rxjs-break is an RxJS library that allows breakpoints to be added directly into the obserable stream. It implements a new BreakpointOperator that passes the values through a callback that can be used as a breakpoint. Including rxjs-break as a webpack loader will automatically wrap all .pipe(...) operators with breakpoints.

Why might you need it?

If you add breakpoint to a RxJS pipeable operator it will hit the breakpoint during creation of the obserable, but not when the pipeable is invoked. This can make pipes hard to debug.

Install

Install the package using NPM:

npm install rxjs-break --save-dev

Usage

rxjs-break contains a webpack loader.

webpack.config.js

// webpack.config.js
module.exports = {
  module: {
    rules: [
      {
        test: /\.tsx?$/i,
        use: [
          'rxjs-break',
          // i.e. add rxjs-break as the entry before ts-loader or @ngtools/webpack
          // ...
         ]
      },
    ],
  },
};

Notes

Only operators inside a .pipe(...) are patched and refCount operator and operators using spread ... are ignored for now.

About

RxJS operator breakpoint library

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published