This package has been deprecated

Author message:

This package is no longer used by any cf-ui packages or cloudflare

cf-pony

1.3.0 • Public • Published

cf-pony

Big Horse

Cloudflare ponyfills

We are wrapping other modules so that we can deprecate them in the future with console.warn warnings. We can also swap out implementations easily.

Installation

$ npm install cf-pony

Usage

setImmediate

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.setImmediate(function() {
  // ...
});

requestAnimationFrame

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.requestAnimationFrame(function() {
  // ...
});

cancelAnimationFrame

Use the ponyfill from this module.

var cf = require('cf-pony');
var id = cf.requestAnimationFrame(function() {
  // ...
});
cf.cancelAnimationFrame(id);

Array.isArray

Use the native method.

Array.isArray(arr);

Array.prototype.every

Use the native method.

arr.every(function() {
  // ...
});

Array.prototype.filter

Use the native method.

arr.filter(function() {
  // ...
});

Array.prototype.find

Use the native method.

arr.find(function() {
  // ...
});

Array.prototype.forEach

Use the native method.

arr.forEach(function() {
  // ...
});

Array.prototype.includes => cf.arrayIncludes

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.arrayIncludes(arr, 'item');

Array.prototype.map

Use the native method.

arr.map(function() {
  // ...
});

Array.prototype.reduce

Use the native method.

arr.reduce(function() {
  // ...
});

Array.prototype.some

Use the native method.

arr.some(function() {
  // ...
});

Object.assign => cf.objectAssign

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.objectAssign(obj, obj2);

Object.create

Use the native method.

Object.create(obj);

Object.is => cf.objectIs

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.objectIs(obj, val);

Object.keys

Use the native method.

Object.keys(obj);

Object.prototype.hasOwnProperty

Use the native method.

obj.hasOwnProperty('prop');

String.prototype.endsWith => cf.stringEndsWith

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.stringEndsWith(str, 'string');

String.prototype.includes => cf.stringIncludes

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.stringIncludes(str, 'string');

String.prototype.startsWith => cf.stringStartsWith

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.stringStartsWith(str, 'string');

String.prototype.trim => cf.stringTrim

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.stringTrim(str);

String.prototype.trimLeft => cf.stringTrimLeft

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.stringTrimLeft(str);

String.prototype.trimRight => cf.stringTrimRight

Use the ponyfill from this module.

var cf = require('cf-pony');
cf.stringTrimRight(str);

Readme

Keywords

none

Package Sidebar

Install

npm i cf-pony

Weekly Downloads

25

Version

1.3.0

License

BSD-3-Clause

Last publish

Collaborators

  • lerwincf
  • lbarthonet
  • cf-media-manager
  • jacobbednarz
  • celso
  • cf-radar
  • dash_service_account
  • g4brym
  • snigdha34
  • wrangler-publisher
  • marksteyn
  • chiminator
  • sgoodhew_cf
  • terinjokes
  • third774
  • jsteinberger
  • jasnell
  • asapzacy
  • pcostanzo
  • gregbrimble
  • geelen
  • rexscaria
  • dcruz_cf
  • xuranwang
  • jculvey
  • sejoker
  • vasturiano
  • cf-ci-write
  • segments-write
  • thibmeu
  • xortive
  • gurjinder
  • cf-ci2
  • lvalenta
  • worenga