To set up the instrumentation, you'll need to add a plugin to the ESBuild build configuration.
Note: Enabling instrumentation has a considerable performance and memory footprint. Make sure not to enable it in production mode.
npm install --save-dev @rxjs-insights/rxjs7
Note: The version of the
@rxjs-insights/rxjs<version>
package needs to match the version of RxJS. For example, if you are using RxJS 6, you need to runnpm install --save-dev @rxjs-insights/rxjs6
.
npm install --save-dev @rxjs-insights/plugin-esbuild
// development.build.js
const esbuild = require('esbuild');
const { rxjsInsightsPlugin } = require('@rxjs-insights/plugin-esbuild');
esbuild.build({
// (...)
plugins: [rxjsInsightsPlugin()]
// (...)
});