9 lines
305 B
TypeScript
Raw Normal View History

2019-08-31 20:51:14 -07:00
import { typeOf } from '@ember/utils';
/**
* Checks if a type is an object
* @param {any} candidate the entity to check
*/
// @ts-ignore https://github.com/typed-ember/ember-cli-typescript/issues/799
2019-08-31 20:51:14 -07:00
export const isObject = (candidate: unknown): candidate is object => typeOf(candidate) === 'object';