JSPM

  • Created
  • Published
  • Downloads 219
  • Score
    100M100P100Q66820F
  • License ISC

This module allows you to quickly and safely validate variables against a defined template, enforced by Typescript. No hasstle and easy to scan.

Package Exports

  • simple-type-guard

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (simple-type-guard) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Simple Type Guard

Installation

$ npm i -D simple-type-guard

Why Simple Type Guard?

Simple Type Guard takes the guess-work out of validating unknown variables against a type.

No longer will you have to carefully review your code to make sure you're validating every detail of an object to see if it fits.

Simple Type Guard will help you craft the template that perfectly matches your interface and warns you if something is missing or improperly defined.

Even better, you don't have to learn a new pattern or all the facets of a new library. The templates you match against are all standard Javascript.

All you have to do is provide a Generic type!

Examples