UNPKG

hamjest

Version:

A library of composable matchers for defining meaningful and readable assertions in JavaScript.

11 lines (8 loc) 193 B
'use strict'; const getTypeName = require('./getTypeName'); module.exports = function (value) { if (!value.constructor) { return '<no type>'; } return getTypeName(value.constructor); };