Skip to content
@inspect-js

Inspect JS

JavaScript value inspection tools.

inspect-js

This github and npm organization houses JavaScript projects that help you look at stuff.

Predicates

Functions that ask a question and produce a yes or no answer (`true` or `false`).
  • defined - github - npm - return the first argument that is !== undefined
  • is-accessor-descriptor - github - npm - Returns true if a value has the characteristics of a valid JavaScript accessor descriptor.
  • is-arguments - github - npm - Is this an arguments object? It's a harder question than you think.
  • is-array-buffer - github - npm - Is this value a JS ArrayBuffer?
  • is-arrow-function - github - npm - Determine if a function is an ES6 arrow function or not.
  • is-async-function - github - npm - Determine if a function is a native async function.
  • is-bigint - github - npm - Is this value an ES BigInt?
  • is-boolean-object - github - npm - Is this value a JS Boolean? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
  • is-boxed-primitive - github - npm - Is this value a boxed primitive? Shim for node's util.isBoxedPrimitive.
  • is-callable - github - npm - Is this JS value callable? Works with Functions and GeneratorFunctions, despite ES6 @@toStringTag.
  • is-core-module - github - npm - Is this specifier a node.js core module?
  • is-data-descriptor - github - npm - Returns true if a value has the characteristics of a valid JavaScript data descriptor.
  • is-data-view - github - npm - Is this value a JS DataView? This module works cross-realm/iframe, does not depend on instanceof or mutable properties, and despite ES6 Symbol.toStringTag.
  • is-date-object - github - npm - Is this value a JS Date object? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
  • is-descriptor - github - npm - Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors.
  • is-finalizationregistry - github - npm - Is this value a JS FinalizationRegistry? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
  • is-generator-function - github - npm - Determine if a function is a native generator function.
  • is-map - github - npm - Is this value a JS Map? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
  • is-negative-zero - github - npm - Is this value negative zero? === will lie to you
  • is-number-object - github - npm - Is this value a JS Number object? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
  • is-object - github - npm - Checks whether a value is an object
  • is-package-root - github - npm - Is this directory path the root of a package?
  • is-regex - github - npm - Is this value a JS regex? Works cross-realm/iframe, and despite ES6 @@toStringTag
  • is-registered-symbol - github - npm - Is this value a Symbol stored in the global cross-realm Symbol registry?
  • is-set - github - npm - Is this value a JS Set? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
  • is-shared-array-buffer - github - npm - Is this value a JS SharedArrayBuffer?
  • is-string - github - npm - Is this value a JS String object or primitive? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
  • is-symbol - github - npm - Determine if a value is an ES6 Symbol or not.
  • is-typed-array - github - npm - Is this value a JS Typed Array? This module works cross-realm/iframe, does not depend on instanceof or mutable properties, and despite ES6 Symbol.toStringTag.
  • is-weakmap - github - npm - Is this value a JS WeakMap? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
  • is-weakref - github - npm - Is this value a JS WeakRef? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
  • is-weakset - github - npm - Is this value a JS WeakSet? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
  • is-well-known-symbol - github - npm - Is this value a well-known Symbol?

Comparisons

Packages that compare two things.
  • buffer-equal - github - npm - return whether two buffers are equal
  • deep-equal-json - github - npm - deep-equal, but only for JSON-supported values.
  • is-equal - github - npm - Are these two values conceptually equal?
  • deep-equal - github - npm - node's assert.deepEqual algorithm

Environment

Packages that tell you about the JS env.
  • available-regexp-flags - github - npm - Which regular expression flags does the current environment support?
  • available-typed-arrays - github - npm - Returns an array of Typed Array names that are available in the current environment
  • functions-have-names - github - npm - Does this JS environment support the name property on functions?
  • has-bigints - github - npm - Determine if the JS environment has BigInt support.
  • has-dynamic-import - github - npm - Does the current environment have import() support?
  • has-named-captures - github - npm - Does the JS environment support named capture groups in regexes?
  • has-object-spread - github - npm - check if the environment supports { ...a } spread syntax
  • has-optional-chaining - github - npm - Determine if the JS environment has optional chaining support
  • has-override-mistake - github - npm - Determine whether the environment has the so-called "override mistake" - [[Set]]ing a property whose ancestor is nonwritable throws.
  • has-package-exports - github - npm - Does the current node version have support for the "exports" field in package.json?
  • has-package-imports - github - npm - Does the current node version have support for the "imports" field in package.json?
  • has-package-self-reference - github - npm - Does the current node version have support for requiring/importing its own name?
  • has-private-fields - github - npm - Determine if the JS environment has private fields (class { #x; }) support.
  • has-property-descriptors - github - npm - Does the environment have full property descriptor support? Handles IE 8's broken defineProperty/gOPD.
  • has-proto - github - npm - Does this environment have the ability to get the [[Prototype]] of an object on creation with __proto__?
  • has-strict-mode - github - npm - Does the current JS environment have strict mode? ES5+ should; but let's not assume.
  • has-symbols - github - npm - Determine if the JS environment has Symbol support. Supports spec, or shams.
  • has-template-literals - github - npm - Determine if the JS environment has template literal support.
  • has-tostringtag - github - npm - Determine if the JS environment has Symbol.toStringTag support. Supports spec, or shams.
  • has-typed-arrays - github - npm - Does this environment have JS Typed Arrays?
  • hasown - github - npm - A robust, ES3 compatible, "has own property" predicate.
  • node-exports-info - github - npm - Info about node exports field support: version ranges, categories, etc.
  • supports-preserve-symlinks-flag - github - npm - Determine if the current node version supports the --preserve-symlinks flag.

Describe

Packages that tell you about a specific JS value.
  • array-buffer-byte-length - github - npm - Get the byte length of an ArrayBuffer, even in engines without a .byteLength method.
  • data-view-buffer - github - npm - Get the ArrayBuffer out of a DataView, robustly.
  • data-view-byte-length - github - npm - Get the byteLength out of a DataView, robustly.
  • data-view-byte-offset - github - npm - Get the byteOffset out of a DataView, robustly.
  • get-symbol-description - github - npm - Gets the description of a Symbol. Handles Symbol() vs Symbol('') properly when possible.
  • object-inspect - github - npm - string representations of objects in node and the browser
  • typed-array-buffer - github - npm - Get the ArrayBuffer out of a TypedArray, robustly.
  • typed-array-byte-length - github - npm - Robustly get the byte length of a Typed Array
  • typed-array-byte-offset - github - npm - Robustly get the byte offset of a Typed Array
  • typed-array-length - github - npm - Robustly get the length of a Typed Array
  • which-boxed-primitive - github - npm - Which kind of boxed JS primitive is this?
  • which-builtin-type - github - npm - What is the type of this builtin JS value?
  • which-collection - github - npm - Which kind of Collection (Map, Set, WeakMap, WeakSet) is this JavaScript value? Works cross-realm, without instanceof, and despite Symbol.toStringTag.
  • which-typed-array - github - npm - Which kind of Typed Array is this JavaScript value? Works cross-realm, without instanceof, and despite Symbol.toStringTag.

Pinned

  1. node-deep-equal node-deep-equal Public

    node's assert.deepEqual algorithm

    JavaScript 761 111

  2. object-inspect object-inspect Public

    string representations of objects in node and the browser

    JavaScript 132 34

  3. is-callable is-callable Public

    Is this JS value callable? Works with Functions and GeneratorFunctions, despite ES6 @@toStringTag.

    JavaScript 41 12

  4. is-equal is-equal Public

    Are these two values conceptually equal?

    JavaScript 61 7

  5. which-typed-array which-typed-array Public

    Which kind of Typed Array is this JavaScript value? Works cross-realm, without `instanceof`, and despite Symbol.toStringTag.

    JavaScript 12 4

  6. which-boxed-primitive which-boxed-primitive Public

    Which kind of boxed JS primitive is this?

    JavaScript 8 2

Repositories

Showing 10 of 76 repositories

Top languages

Loading…

Most used topics

Loading…