UNPKG

apphouse

Version:

Component library for React that uses observable state management and theme-able components.

10 lines (9 loc) 294 B
/** * Converts an object to an array of key-value pairs. * * @param {Record<string, any>} obj - The object to be converted. * @returns {[string, any][]} - The array of key-value pairs. */ export function toArray(obj: Record<string, any>): [string, any][] { return Object.entries(obj); }