javascript list all object functions code example
Example 1: list methods of object js
Object.getOwnPropertyNames(obj)
Example 2: list all functions in an object js
getMethods = (obj) => Object.getOwnPropertyNames(obj).filter(item => typeof obj[item] === 'function')