"foo" instanceof String //=> false "foo" instanceof Object //=> false true instanceof Boolean //=> false true instanceof Object //=>
I believe I have come up with a viable solution:
Object.getPrototypeOf('test') === String.prototype //true Object.getPrototypeOf(1) === String.prototype //false