| /* global Map,Set,Symbol */ |
| // Based on https://kangax.github.io/compat-table/es6/ we can sniff out |
| // incomplete Map/Set implementations which would otherwise cause our tests to fail. |
| // Notably they fail in IE11 and iOS 8.4, which this prevents. |
| function supportsMapAndSet() { |
| if (typeof Symbol === 'undefined' || typeof Map === 'undefined' || typeof Set === 'undefined') { |
| return false; |
| } |
| var prop = Object.getOwnPropertyDescriptor(Map, Symbol.species); |
| return prop && 'get' in prop && Map[Symbol.species] === Map; |
| } |
| export default supportsMapAndSet; |