Skip to content

Instantly share code, notes, and snippets.

@brixdan
Last active April 9, 2019 10:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save brixdan/0eb329ca12aa144ad83ebca53e7a1c2b to your computer and use it in GitHub Desktop.
Save brixdan/0eb329ca12aa144ad83ebca53e7a1c2b to your computer and use it in GitHub Desktop.
#!/usr/bin/env node
console.log('yay gist')
const o = {
'0': 'zero',
'1': 'one'
};
console.log([].slice.call(o)); // [];
const oo = {
'0': 'zero',
'1': 'one',
length: 2
};
console.log([].slice.call(oo)); // ["zero", "one"];
{"name": "npx-is-cool", "version": "0.0.0", "bin": "./index.js"}
@brixdan
Copy link
Author

brixdan commented Apr 9, 2019

[]
[ 'zero', 'one' ]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment