Functions are indeed objects in JS, however:
'function' === typeof (function(){}) while 'object' === typeof ({})
There are no classes in JavaScript, the way there are in some OO languages.
The new syntax of 'class' introduced in ES6 is just a synthetic sugar which will be translated to an Object and would use inheritance via the prototype chain.
I suggest the book 'JavaScript: The good parts' (by Douglas Crockford) for more on this topic.