• Version 1.2.35
  • Published
  • 5.41 kB
  • 2 dependencies
  • MIT license


npm i @types/empower
yarn add @types/empower
pnpm add @types/empower


TypeScript definitions for empower



function defaultOptions

defaultOptions: () => Required<Options>;
  • Returns default options object for empower function.

function empower

empower: typeof empower;
  • Enhances Power Assert feature to assert function/object.

    Parameter originalAssert

    An instance of standard assert function or any assert-like object to enhance.

    Parameter formatter

    A formatter function created by power-assert-formatter.

    Parameter options

    Configuration options. If not passed, default options will be used. Enhanced assert function/object.

Type Aliases

type Options

type Options = Omit<CoreOptions, 'modifyMessageBeforeAssert' | 'onError'> & {
* If truthy, modify message property of `AssertionError` on rethrow.
* @default false
modifyMessageOnRethrow?: boolean | undefined;
* If truthy, add `powerAssertContext` property to `AssertionError` on rethrow.
* @default false
saveContextOnRethrow?: boolean | undefined;

    Package Files (1)

    Dependencies (2)

    Dev Dependencies (0)

    No dev dependencies.

    Peer Dependencies (0)

    No peer dependencies.


    To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

    You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@types/empower.

    • Markdown
    • HTML
      <a href="https://www.jsdocs.io/package/@types/empower"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>