Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

es-aggregate-error

es-shims7.3mMIT1.0.14TypeScript support: definitely-typed

ES Proposal spec-compliant shim for AggregateError

AggregateError, Error, aggregate, errors, nativeerror, es-shim API, shim, polyfill

readme

es-aggregate-error Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

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('es-aggregate-error');

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

changelog

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog and this project adheres to Semantic Versioning.

v1.0.14 - 2025-06-01

Commits

  • [Deps] update es-abstract, globalthis ddcdc9d
  • [Dev Deps] update @es-shims/api, @ljharb/eslint-config, auto-changelog, for-each, object-inspect, tape f760355
  • [Tests] replace aud with npm audit 8497f42
  • [Dev Deps] add missing peer dep 657a7ad

v1.0.13 - 2024-03-22

Commits

  • [Deps] update es-abstract, set-function-name 8a923d8
  • [actions] remove redundant finisher 7b4a423
  • [Deps] update define-data-property, es-abstract, es-errors, has-property-descriptors dac80ec
  • [Dev Deps] update tape aa3ff65

v1.0.12 - 2024-02-04

Commits

  • [Deps] update define-data-property, es-abstract, function-bind, get-intrinsic, has-property-descriptors e58ffc2
  • [Dev Deps] update aud, npmignore, object-inspect, tape 78fe590
  • [Refactor] use es-errors where possible, so things that only need those do not need get-intrinsic 9c69ddd

v1.0.11 - 2023-09-13

Commits

  • [Refactor] use define-data-property, set-function-name 68b182f
  • [Deps] update define-properties, set-function-name 8c0491e

v1.0.10 - 2023-08-26

Commits

  • [Deps] update define-properties, es-abstract, get-intrinsic 567696f
  • [Tests] remove invalid receiver tests; add "as a function" tests 97e050d
  • [Dev Deps] update @es-shims/api, @ljharb/eslint-config, aud, es6-shim, object-inspect, tape c6fbf1d
  • [Deps] update es-abstract 138527c
  • [Dev Deps] update aud e98e027

v1.0.9 - 2022-11-02

Commits

  • [Deps] update es-abstract, get-intrinsic, globalthis 8fe0dd4
  • [actions] update rebase action to use reusable workflow 12fbd34
  • [Dev Deps] update aud, object-inspect, tape 035dade

v1.0.8 - 2022-05-04

Commits

  • [actions] reuse common workflows 551e610
  • [meta] use npmignore to autogenerate an npmignore file 2b9c9f6
  • [Fix] ensure AggregateError.prototype is nonwritable 53c59b4
  • [Dev Deps] update eslint, @ljharb/eslint-config, @es-shims/api, safe-publish-latest, tape db50863
  • [Dev Deps] update eslint, @ljharb/eslint-config, aud, auto-changelog, object-inspect, tape ca73cf7
  • [actions] update codecov uploader e5689ca
  • [Deps] update define-properties, es-abstract, functions-have-names e0b0863
  • [Deps] update es-abstract d41de34

v1.0.7 - 2021-09-30

Commits

  • [meta] do not publish Github Actions workflows 303ffe3

v1.0.6 - 2021-09-30

Commits

  • [actions] use node/install instead of node/run; use codecov action 5a9b28c
  • [Deps] update es-abstract 9d62677
  • [Dev Deps] update eslint, @ljharb/eslint-config, @es-shims/api, aud, auto-changelog, object-inspect, tape 2c14b62
  • [readme] fix repo URLs; remove travis badge 5097d6a
  • [Dev Deps] update eslint, @ljharb/eslint-config, aud, tape cf7500b
  • [Dev Deps] update eslint, @ljharb/eslint-config, has-strict-mode, object-inspect, tape 41f8949
  • [actions] update workflows 04d88f9
  • [readme] add github actions/codecov badges 3e84f08
  • [Deps] update es-abstract, get-intrinsic, globalthis 70e9947
  • [Deps] update es-abstract, functions-have-names, get-iintrinsic e68ae0b
  • [meta] use prepublishOnly, for npm 7+ 2858f55
  • [Tests] improve coverage ab5858a

v1.0.5 - 2020-11-22

Commits

  • [Tests] migrate tests to Github Actions 1b83d28
  • [Tests] add implementation test; run es-shim-api in postlint; use tape runner 952f9a2
  • [Tests] run nyc on all tests ce5728a
  • [Deps] update es-abstract; use get-intrinsic where applicable b4999f9
  • [actions] add "Allow Edits" workflow 493b21d
  • [Dev Deps] update eslint, @ljharb/eslint-config, aud, auto-changelog, es6-shim 43cc5ca
  • [actions] switch Automatic Rebase workflow to pull_request_target event 95c0a09

v1.0.4 - 2020-08-08

Fixed

  • [Fix] use Object.defineProperty instead of assignment to set the entry point .prototype #12

Commits

  • [Dev Deps] update auto-changelog, eslint, object-inspect a87fbed
  • [meta] update auto-changelog settings 5cb7179
  • [Deps] update es-abstract 252bc1a
  • [Tests] remove confusing comment ee9ea50
  • [Tests] add missing covert dep f848aa2

v1.0.3 - 2020-06-04

Commits

  • [patch] spec change; errors is now an own data instead of a prototype accessor 9d8750c
  • [patch] spec change; errors is validated/processed after stringifying and setting message 890d344
  • [Dev Deps] update eslint, @ljharb/eslint-config, aud, tape 488dfd3
  • [Dev Deps] update eslint, @ljharb/eslint-config, tape 83bc687
  • [Deps] update es-abstract, functions-have-names, globalthis, internal-slot 4a86017
  • [Docs] fix Travis CI link in README.md aa712e3
  • [Dev Deps] update auto-changelog, tape 27d054d
  • [Dev Deps] update auto-changelog; add aud 08edc48
  • [Deps] update es-abstract 8e33737
  • [Tests] only audit prod deps 56599f2

v1.0.2 - 2019-12-13

Commits

  • [Refactor] use split-up es-abstract (67% bundle size decrease) fcca181
  • [meta] switch to keepachangelog template 61c9af8
  • [actions] add automatic rebasing / merge commit blocking d9840cd
  • [Deps] update es-abstract, internal-slot 71aaa2e
  • [Tests] use evalmd in postlint 5081797
  • [Dev Deps] update eslint, @ljharb/eslint-config 7a8486c
  • [meta] fix missing version npmrc settings 10c271e

v1.0.1 - 2019-11-11

Commits

  • [Tests] use shared travis-ci configs 4acd21b
  • [Dev Deps] update eslint, @ljharb/eslint-config, safe-publish-latest, object-inspect, auto-changelog 668dd27
  • [Fix] remove own AggregateError.prototype.toString 86da74a
  • [meta] add funding field 3673ad9

v1.0.0 - 2019-10-21

Commits

  • [Tests] add travis.yml 71ad01b
  • Implementation f67c101
  • Tests 5cda887
  • Initial commit 370054f
  • [Refactor] use internal-slot 972cb6b
  • readme 562715e
  • npm init cf3b5b3
  • [tests] add npm run lint bc6cca9
  • [meta] add safe-publish-latest, auto-changelog b415df1
  • [Tests] skip name test when bound functions do not have names 693e161
  • Only apps should have lockfiles 315a27e
  • [Refactor] use functions-have-names c42a982
  • [Dev Deps] update eslint, @ljharb/eslint-config a7afeea