source: trip-planner-front/node_modules/core-js/modules/es.string.includes.js@ 571e0df

Last change on this file since 571e0df was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 722 bytes
Line 
1'use strict';
2var $ = require('../internals/export');
3var notARegExp = require('../internals/not-a-regexp');
4var requireObjectCoercible = require('../internals/require-object-coercible');
5var toString = require('../internals/to-string');
6var correctIsRegExpLogic = require('../internals/correct-is-regexp-logic');
7
8// `String.prototype.includes` method
9// https://tc39.es/ecma262/#sec-string.prototype.includes
10$({ target: 'String', proto: true, forced: !correctIsRegExpLogic('includes') }, {
11 includes: function includes(searchString /* , position = 0 */) {
12 return !!~toString(requireObjectCoercible(this))
13 .indexOf(toString(notARegExp(searchString)), arguments.length > 1 ? arguments[1] : undefined);
14 }
15});
Note: See TracBrowser for help on using the repository browser.