Skip to content

Tiny module for checking if Promise is globally available

License

Notifications You must be signed in to change notification settings

vigreco/can-promise

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

can-promise

Tiny module for checking if Promise is globally available.

Installation

npm i --save can-promise

Example

const canPromise = require('can-promise')
// or
import canPromise from 'can-promise'

// on Node < 0.11.13
console.log(canPromise()) // false

// on Node >= 0.11.13
console.log(canPromise()) // true

// on IE9
console.log(canPromise()) // false

// on Chrome, Firefox
console.log(canPromise()) // true

About

Tiny module for checking if Promise is globally available

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published