/
buuded
/
app-web-project
Обзор
Документация
Войти
/
buuded
/
app-web-project
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
node_modules/array.prototype.flatmap/shim.js
20 строк
414 B
buuded
first-commit
27 янв 2025, 10:32
27 янв 2025, 10:32
9efc400
Код
Авторство
О чём код?
'use strict'; var define = require('define-properties'); var shimUnscopables = require('es-shim-unscopables'); var getPolyfill = require('./polyfill'); module.exports = function shimFlatMap() { var polyfill = getPolyfill(); define( Array.prototype, { flatMap: polyfill }, { flatMap: function () { return Array.prototype.flatMap !== polyfill; } } ); shimUnscopables('flatMap'); return polyfill; };