A Babel plugin that provides compile-time protection against improper use of `t.throws()` in the AVA test framework. It transforms code to detect when a value rather than a function is passed, issuing clear error messages. This plugin is internal to AVA and not intended for direct use; version 1.0.0 is the current stable release, with no recent updates. It differs from eslint-plugin-ava by offering a more robust, AST-based solution for a common mistake where users write `t.throws(foo())` instead of `t.throws(() => foo())`.
npm install babel-plugin-ava-throws-helperVerified import paths — ran on the pinned version, not inferred.
Shows installation, Babel configuration, and usage of the plugin to catch incorrect t.throws() calls.
Ensure AVA version compatibility; this plugin is internal and may be removed in future AVA releases.
Always wrap t.throws() arguments in a function as best practice.
Install the missing preset: npm install babel-preset-stage-2 --save-dev
Ensure AVA is installed and you are running tests with 'npx ava'