@intlayer/core
Version:
Includes core Intlayer functions like translation, dictionary, and utility functions shared across multiple packages.
13 lines (12 loc) • 453 B
JavaScript
//#region src/utils/isValidReactElement.ts
/**
* Verifies the object is a ReactElement.
* See https://reactjs.org/docs/react-api.html#isvalidelement
* @param object
* @return True if `object` is a ReactElement.
* @final
*/
const isValidElement = (object) => typeof object === "object" && typeof object?.key !== "undefined" && typeof object?.props !== "undefined";
//#endregion
export { isValidElement };
//# sourceMappingURL=isValidReactElement.mjs.map