UNPKG

charlike

Version:

Small, fast, simple and streaming project scaffolder for myself, but not only. Supports hundreds of template engines through the @JSTransformers API or if you want custom `render` function passed through options

11 lines (8 loc) 273 B
'use strict'; var iteratorSymbol = require('es6-symbol').iterator , isArrayLike = require('../object/is-array-like'); module.exports = function (x) { if (x == null) return false; if (typeof x[iteratorSymbol] === 'function') return true; return isArrayLike(x); };