Well, you don't need to check everything by yourself or write your own codes, when there are good libraries such as Lodash and Underscore.
In Lodash, you can easily check it by isPlainObject function, e.g.:
_.isPlainObject({'a': 12});
Check this page: https://lodash.com/docs#isPlainObject