RxJS operator breakpoint library
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.
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 the package using NPM:
npm install rxjs-break --save-dev
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
// ...
]
},
],
},
};
Only operators inside a .pipe(...)
are patched and refCount
operator and operators using spread ...
are ignored for now.