https://github.com/kensho-technologies/check-more-types https://github.com/jquery-validation/jquery-validation/blob/master/src/core.js https://github.com/iarna/aproba https://github.com/gcanti/tcomb/tree/master/lib https://github.com/apollographql/graphql-anywhere/blob/master/src/utilities.ts#L60 https://github.com/apollographql/graphql-anywhere/blob/master/src/storeUtils.ts
problem:
// @NOTE isNull & isUndefined to lowercase is no good... // one way to do it, but not as good // const TYPES = ['null', 'undefined'] // const REPLACE = ['nill', 'undef'] // .replace(TYPES[0], REPLACE[0]) // .replace(TYPES[1], REPLACE[1]) // // @NOTE: removed this in favor of escaping the key // plus this 2x the map size // // const ObjectKeys = require('chaintools/util/keys') // const validationKeys = ObjectKeys(is) // for (let i = 0; i < validationKeys.length; i++) { // const key = validationKeys[i] // const transformedKey = key.toLowerCase().replace('is', '') // is[transformedKey] = is[key] // } // s.charAt(0).toUpperCase()