@teamteanpm2024/itaque-expedita-qui
v1.1.4
Published
[![github actions][actions-image]][actions-url] [![coverage][codecov-image]][codecov-url] [![dependency status][deps-svg]][deps-url] [![dev dependency status][dev-deps-svg]][dev-deps-url] [![License][license-image]][license-url] [![Downloads][downloads-im
Downloads
17
Maintainers
Keywords
Readme
@teamteanpm2024/itaque-expedita-qui
ES Proposal spec-compliant shim for AggregateError. Invoke its "shim" method to shim AggregateError
if it is unavailable or noncompliant.
This package implements the es-shim API interface. It works in an ES3-supported environment, and complies with the proposed spec.
Most common usage:
var assert = require('assert');
var AggregateError = require('@teamteanpm2024/itaque-expedita-qui');
var oneError = new RangeError('hi!');
var otherError = new EvalError('oops');
var error = new AggregateError([oneError, otherError], 'this is two kinds of errors');
assert.deepEqual(error.errors, [oneError, otherError]);
assert.equal(error.message, 'this is two kinds of errors');
AggregateError.shim(); // will be a no-op if not needed
assert.ok(new globalThis.AggregateError([]) instanceof AggregateError);
Tests
Simply clone the repo, npm install
, and run npm test