1. istanbul-lib-instrument
Core istanbul API for JS code coverage
istanbul-lib-instrument
Package: istanbul-lib-instrument
Created by: istanbuljs
Last modified: Mon, 19 Feb 2024 20:50:24 GMT
Version: 6.0.2
License: BSD-3-Clause
Downloads: 161,381,222
Repository: https://github.com/istanbuljs/istanbuljs

Install

npm install istanbul-lib-instrument
yarn add istanbul-lib-instrument

istanbul-lib-instrument

Build Status

Istanbul instrumenter library.

Version 1.1.x now implements instrumentation using Babel. The implementation is inspired
by prior art by @dtinth as demonstrated in the __coverage__ babel plugin.

It provides 2 "modes" of instrumentation.

  • The old API that is mostly unchanged (except for incompatibilities noted) and
    performs the instrumentation using babel as a library.

  • A programVisitor function for the Babel AST that can be used by a Babel plugin
    to emit instrumentation for ES6 code directly without any source map
    processing. This is the preferred path for babel users. The Babel plugin is
    called babel-plugin-istanbul.

Incompatibilities and changes to instrumentation behavior can be found in
v0-changes.md.

RELATED POST

Enhancing Vue.js Development: Harnessing the Potential of Vue-Loader

Enhancing Vue.js Development: Harnessing the Potential of Vue-Loader

Simplify Data Validation in Vue.js: A Step-by-Step Guide to Using Regex

Simplify Data Validation in Vue.js: A Step-by-Step Guide to Using Regex

Troubleshooting Made Easy: Common Issues and Solutions with vue-loader Without vue-cli

Troubleshooting Made Easy: Common Issues and Solutions with vue-loader Without vue-cli

Optimizing Webpack 4 with Vue CLI 3: Disabling the Cache-Loader

Optimizing Webpack 4 with Vue CLI 3: Disabling the Cache-Loader

Step-by-Step Guide: How to Add a Function to Your Vuex Plugin

Step-by-Step Guide: How to Add a Function to Your Vuex Plugin