JSFiddle - React, Tailwind, and code Playground
by Cody Lindley
HTML
<script src="https://dl.dropboxusercontent.com/u/2026291/firebug-lite-debug.js"></script>
JavaScript
var person = {};
Object.defineProperties(person,
{
"name": {value: 'Cody Lindley',enumerable: true},
"age": {value: 38,enumerable: false}
}
);
//return array of all properties that are enumerable
console.log(Object.keys(person)); //logs ["name"]
//return array of all properties, including ones that are non-enumerable
console.log(Object.getOwnPropertyNames(person)); //returns ["name", "age"]