UNPKG

@toolpad/utils

Version:

Shared utilities used by Toolpad packages.

7 lines 275 B
/** * Returns a Promise to an object with all the properties resolved as promises */ export async function resolveValues(obj) { const entries = Object.entries(obj).map(async ([key, value]) => [key, await value]); return Object.fromEntries(await Promise.all(entries)); }