{"library":"type-of-is","type":"library","category":null,"description":"type-of-is provides a reliable mechanism for JavaScript type detection and comparison, addressing the well-known quirks of the native `typeof` operator (e.g., `typeof null` being 'object', or arrays being 'object'). It uses a combination of `Object.prototype.toString` and constructor checks to determine the true type of a value, including primitives, built-in objects, and custom constructors. The package is currently at version 3.5.1, though the latest publicly listed version on npm (3.4.0) was published in February 2017, suggesting a very slow or effectively halted release cadence. Its key differentiator is its commitment to 'sensible / unsurprising' type results, making it suitable for validation and conditional logic where native `typeof` falls short. It offers functions like `Type.of` to get the constructor, `Type.string` for a string representation, and `Type.is` for comparison against a type or string.","language":"javascript","status":"maintenance","version":"3.5.1","tags":["javascript","type","types","typeof","toString","type.of","type.is"],"last_verified":"Wed May 27","install":[{"cmd":"npm install type-of-is","imports":["import Type from 'type-of-is';","import Type from 'type-of-is';\nconst typeName = Type.of({});","const Type = require('type-of-is');"]},{"cmd":"yarn add type-of-is","imports":[]},{"cmd":"pnpm add type-of-is","imports":[]}],"homepage":null,"github":"https://github.com/stephenhandley/type-of-is","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/type-of-is","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/type-of-is/compatibility"}}