Version 1
[yaffs-website] / node_modules / core-js / modules / es6.array.find.js
1 'use strict';
2 // 22.1.3.8 Array.prototype.find(predicate, thisArg = undefined)
3 var $export = require('./_export')
4   , $find   = require('./_array-methods')(5)
5   , KEY     = 'find'
6   , forced  = true;
7 // Shouldn't skip holes
8 if(KEY in [])Array(1)[KEY](function(){ forced = false; });
9 $export($export.P + $export.F * forced, 'Array', {
10   find: function find(callbackfn/*, that = undefined */){
11     return $find(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
12   }
13 });
14 require('./_add-to-unscopables')(KEY);