is-string.js 291 B

12345678910111213
  1. "use strict";
  2. var objToString = Object.prototype.toString, id = objToString.call("");
  3. module.exports = function (value) {
  4. return (
  5. typeof value === "string" ||
  6. (value &&
  7. typeof value === "object" &&
  8. (value instanceof String || objToString.call(value) === id)) ||
  9. false
  10. );
  11. };