@reverse/utils
TypeScript icon, indicating that this package has built-in type declarations

1.3.8 • Public • Published

@reverse/utils

Really simple utility functions used by other @reverse packages

You can install with nodejs and npm

npm i @reverse/utils

Table of Contents

catchFallback

Runs the passed function into a try/catch block, and if it throws an error it will return the second paramater

catchFallback(() => mightThrowAnError(params), 'default');

switchObject

Returns object[key] or object.default

Dependencies (0)

    Dev Dependencies (0)

      Package Sidebar

      Install

      npm i @reverse/utils

      Weekly Downloads

      3

      Version

      1.3.8

      License

      none

      Unpacked Size

      2.78 kB

      Total Files

      7

      Last publish

      Collaborators

      • davecaruso
      • hparcells
      • imdaveead