Determine if the JS environment has Symbol support. Supports spec, or shams. (Evacuated from NSA/Microsoft Github)
Jordan Harband cb9f0a521a [Dev Deps] update `safe-publish-latest` | hace 8 años | |
---|---|---|
test | hace 8 años | |
.eslintrc | hace 8 años | |
.gitignore | hace 8 años | |
.travis.yml | hace 8 años | |
CHANGELOG.md | hace 8 años | |
LICENSE | hace 8 años | |
README.md | hace 8 años | |
index.js | hace 8 años | |
package.json | hace 8 años | |
shams.js | hace 8 años |
Determine if the JS environment has Symbol support. Supports spec, or shams.
var hasSymbols = require('has-symbols');
hasSymbols() === true; // if the environment has native Symbol support. Not polyfillable, not forgeable.
var hasSymbolsKinda = require('has-symbols/shams');
hasSymbolsKinda() === true; // if the environment has a Symbol sham that mostly follows the spec.
Simply clone the repo, npm install
, and run npm test