get-own-property-symbols-x
Creates an array of all symbol properties found directly upon a given object.
module.exports(obj)
⇒ array
⏏
This method creates an array of all symbol properties found directly upon a given object.
Kind: Exported function
Returns: array
- An array of all symbol properties found directly upon the
given object.
Throws:
TypeError
If target is null or undefined.
Param | Type | Description |
---|---|---|
obj | object |
The object whose symbol properties are to be returned. |
Example
; const symbol = Symbol'';const testObj = a: 1;testObjsymbol = 2;console; // [symbol]