mirror of
				https://github.com/taixingyiji/openit.git
				synced 2025-11-04 14:32:14 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			21 lines
		
	
	
		
			608 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			21 lines
		
	
	
		
			608 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
var Symbol = require('./_Symbol'),
 | 
						|
    isArguments = require('./isArguments'),
 | 
						|
    isArray = require('./isArray');
 | 
						|
 | 
						|
/** Built-in value references. */
 | 
						|
var spreadableSymbol = Symbol ? Symbol.isConcatSpreadable : undefined;
 | 
						|
 | 
						|
/**
 | 
						|
 * Checks if `value` is a flattenable `arguments` object or array.
 | 
						|
 *
 | 
						|
 * @private
 | 
						|
 * @param {*} value The value to check.
 | 
						|
 * @returns {boolean} Returns `true` if `value` is flattenable, else `false`.
 | 
						|
 */
 | 
						|
function isFlattenable(value) {
 | 
						|
  return isArray(value) || isArguments(value) ||
 | 
						|
    !!(spreadableSymbol && value && value[spreadableSymbol]);
 | 
						|
}
 | 
						|
 | 
						|
module.exports = isFlattenable;
 |