Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
@skava/modules / ___dist / chain-able / src / deps / is / stringPrimitive.js
Size: Mime:
"use strict";

const toS = require("./toS");
/**
 * Checks if `value` is classified as a `String` **primitive**.
 *
 * @since 3.0.0
 * @category Lang
 * @memberOf is
 * @param {*} x The value to check.
 * @returns {boolean} Returns `true` if `value` is a string, else `false`.
 *
 * @see https://github.com/canjs/can-util/blob/master/js/is-string/is-string.js
 * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String
 * @see https://github.com/lodash/lodash/blob/master/isString.js
 * @see is/string
 *
 * @example
 *
 * isString('abc')
 * //=> true
 *
 * isString(new String('abc'))
 * //=> false
 *
 * isString(1)
 * //=> false
 */


module.exports = x => typeof x === 'string';