Mohammad Asif cf937194cb Removed un-waned things 1. преди 5 месеца
..
.github cf937194cb Removed un-waned things 1. преди 5 месеца
test cf937194cb Removed un-waned things 1. преди 5 месеца
.eslintrc cf937194cb Removed un-waned things 1. преди 5 месеца
CHANGELOG.md cf937194cb Removed un-waned things 1. преди 5 месеца
LICENSE cf937194cb Removed un-waned things 1. преди 5 месеца
README.md cf937194cb Removed un-waned things 1. преди 5 месеца
eval.d.ts cf937194cb Removed un-waned things 1. преди 5 месеца
eval.js cf937194cb Removed un-waned things 1. преди 5 месеца
index.d.ts cf937194cb Removed un-waned things 1. преди 5 месеца
index.js cf937194cb Removed un-waned things 1. преди 5 месеца
package.json cf937194cb Removed un-waned things 1. преди 5 месеца
range.d.ts cf937194cb Removed un-waned things 1. преди 5 месеца
range.js cf937194cb Removed un-waned things 1. преди 5 месеца
ref.d.ts cf937194cb Removed un-waned things 1. преди 5 месеца
ref.js cf937194cb Removed un-waned things 1. преди 5 месеца
syntax.d.ts cf937194cb Removed un-waned things 1. преди 5 месеца
syntax.js cf937194cb Removed un-waned things 1. преди 5 месеца
tsconfig.json cf937194cb Removed un-waned things 1. преди 5 месеца
type.d.ts cf937194cb Removed un-waned things 1. преди 5 месеца
type.js cf937194cb Removed un-waned things 1. преди 5 месеца
uri.d.ts cf937194cb Removed un-waned things 1. преди 5 месеца
uri.js cf937194cb Removed un-waned things 1. преди 5 месеца

README.md

es-errors Version Badge

github actions coverage License Downloads

npm badge

A simple cache for a few of the JS Error constructors.

Example

const assert = require('assert');

const Base = require('es-errors');
const Eval = require('es-errors/eval');
const Range = require('es-errors/range');
const Ref = require('es-errors/ref');
const Syntax = require('es-errors/syntax');
const Type = require('es-errors/type');
const URI = require('es-errors/uri');

assert.equal(Base, Error);
assert.equal(Eval, EvalError);
assert.equal(Range, RangeError);
assert.equal(Ref, ReferenceError);
assert.equal(Syntax, SyntaxError);
assert.equal(Type, TypeError);
assert.equal(URI, URIError);

Tests

Simply clone the repo, npm install, and run npm test

Security

Please email @ljharb or see https://tidelift.com/security if you have a potential security vulnerability to report.