es-abstract <sup>Version Badge</sup>

dependency status dev dependency status License Downloads

npm badge

ECMAScript spec abstract operations.

Every operation is available by edition/year and by name - for example, es-abstract/2020/Call gives you the Call operation from ES2020, es-abstract/5/Type gives you the Type operation from ES5.

All abstract operations are also available under an es5/es2015/es2016/es2017/es2018/es2019/es2020/es2021 entry point, and as a property on the main export, but using deep imports is highly encouraged for bundle size and performance reasons. Non-deep entry points will be removed in the next semver-major release.

Example

var ES = require('es-abstract');
var assert = require('assert');

assert(ES.isCallable(function () {}));
assert(!ES.isCallable(/a/g));

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.

es-abstract - Installation

To install es-abstract via this registry, you'll need to install via the --registry parameter with your package manager.

n

NPM

npm install es-abstract --registry https://js.registry.sudovanilla.org

Learn more about the --registry parameter.

Yarn

yarn config set registry https://js.registry.sudovanilla.org
yarn install es-abstract

Learn more about the config option.

PNPM

pnpm install es-abstract --registry https://js.registry.sudovanilla.org

Learn more about the --registry parameter.

Bun Logo

Bun

bun install es-abstract --registry https://js.registry.sudovanilla.org

Learn more about the --registry parameter.

Learn more about setting this up in your bunfig.toml configuration.


For Deno, add the following to your .npmrc file in your directory:

registry="https://js.registry.sudovanilla.org"

Then run the deno install command.

es-abstract - Download

Download Tarball (v1.24.1)

Integrity sha512-zHXBLhP+QehSSbsS9Pt23Gg964240DPd6QCf8WpkqEXxQ7fhdZzYsocOr5u7apWonsS5EjZDmTF+/slGMyasvw==
SHASUM f0c131ed5ea1bb2411134a8dd94def09c46c7899
Tarball https://js.registry.sudovanilla.org/es-abstract/-/es-abstract-1.24.1.tgz