Skip to content

the-minimal/error

Repository files navigation

Example

const AssertionError = error<string>("AssertionError");

// ..

if(typeof value !== "number") {
  AssertionError("number", `Value ${value} should be of type number`);
}

Install

yarn add @the-minimal/error

Benchmark

  • Blue = baseline
  • Orange = Error
  • Green = @the-minimal/error

CPU

CPU benchmark

RAM

RAM benchmark