UNPKG

@webqit/util

Version:

Utility functions used accross multiple JS libraries.

12 lines (10 loc) 200 B
/** * Tells if val is of type "string". * * @param string val * * @return bool */ export default function(val) { return val instanceof String || (typeof val === 'string' && val !== null); };