Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ts-interface-checker

Package Overview
Dependencies
Maintainers
2
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ts-interface-checker - npm Package Compare versions

Comparing version 0.1.9 to 0.1.10

9

dist/types.js

@@ -504,3 +504,12 @@ "use strict";

never: new BasicType(function (v) { return false; }, "is unexpected"),
Date: new BasicType(getIsNativeChecker("[object Date]"), "is not a Date"),
RegExp: new BasicType(getIsNativeChecker("[object RegExp]"), "is not a RegExp"),
};
// This approach for checking native object types mirrors that of lodash. Its advantage over
// `isinstance` is that it can still return true for native objects created in different JS
// execution environments.
var nativeToString = Object.prototype.toString;
function getIsNativeChecker(tag) {
return function (v) { return typeof v === "object" && v && nativeToString.call(v) === tag; };
}
if (typeof Buffer !== "undefined") {

@@ -507,0 +516,0 @@ exports.basicTypes.Buffer = new BasicType(function (v) { return Buffer.isBuffer(v); }, "is not a Buffer");

2

package.json
{
"name": "ts-interface-checker",
"version": "0.1.9",
"version": "0.1.10",
"description": "Runtime library to validate data against TypeScript interfaces",

@@ -5,0 +5,0 @@ "main": "dist/index",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc