Closed Bug 1318933 Opened 4 years ago Closed 5 months ago

Description of `Object.keys` outdated because it does not return symbol keys

Categories

(Developer Documentation Graveyard :: JavaScript, defect, P5)

All
Other
defect

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: mightyiampresence, Unassigned)

References

()

Details

:: Developer Documentation Request

      Request Type: Correction
     Gecko Version: unspecified
 Technical Contact: 

:: Details

`Object.keys` does not "returns an array of a given object's own enumerable properties" because:

```js
let s = Symbol()
let obj = {
  foo: undefined,
  [s]: undefined
}

obj.propertyIsEnumerable('foo')
// true
obj.propertyIsEnumerable(s)
// true

Object.keys(obj)
// [ 'foo' ]
```
MDN Web Docs' bug reporting has now moved to GitHub. From now on, please file content bugs at https://github.com/mdn/sprints/issues/ and platform bugs at https://github.com/mdn/kuma/issues/.
Status: UNCONFIRMED → RESOLVED
Closed: 5 months ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.