Sha256: 8da3e67b0f40bb89788dcecdeb81013cc5da30f2a384181e03866880317055f4

Contents?: true

Size: 845 Bytes

Versions: 12

Compression:

Stored size: 845 Bytes

Contents

'use strict';
var $ = require('../internals/export');
var IS_PURE = require('../internals/is-pure');
var anObject = require('../internals/an-object');
var bind = require('../internals/bind-context');
var getSetIterator = require('../internals/get-set-iterator');
var iterate = require('../internals/iterate');

// `Set.prototype.find` method
// https://github.com/tc39/proposal-collection-methods
$({ target: 'Set', proto: true, real: true, forced: IS_PURE }, {
  find: function find(callbackfn /* , thisArg */) {
    var set = anObject(this);
    var iterator = getSetIterator(set);
    var boundFunction = bind(callbackfn, arguments.length > 1 ? arguments[1] : undefined, 3);
    return iterate(iterator, function (value) {
      if (boundFunction(value, value, set)) return iterate.stop(value);
    }, undefined, false, true).result;
  }
});

Version data entries

12 entries across 12 versions & 4 rubygems

Version Path
disco_app-0.18.0 test/dummy/node_modules/core-js/modules/esnext.set.find.js
disco_app-0.18.2 test/dummy/node_modules/core-js/modules/esnext.set.find.js
condenser-0.0.8 lib/condenser/processors/node_modules/core-js-pure/modules/esnext.set.find.js
jester-data-8.0.0 node_modules/core-js/modules/esnext.set.find.js
ezii-os-5.2.1 node_modules/core-js/modules/esnext.set.find.js
ezii-os-2.0.1 node_modules/core-js/modules/esnext.set.find.js
ezii-os-1.1.0 node_modules/core-js/modules/esnext.set.find.js
ezii-os-1.0.0 node_modules/core-js/modules/esnext.set.find.js
condenser-0.0.7 lib/condenser/processors/node_modules/core-js-pure/modules/esnext.set.find.js
ezii-os-0.0.0.1.0 node_modules/core-js/modules/esnext.set.find.js
ezii-os-0.0.0.0.1 node_modules/core-js/modules/esnext.set.find.js
condenser-0.0.5 lib/condenser/processors/node_modules/core-js-pure/modules/esnext.set.find.js