UNPKG

vike

Version:

The Framework *You* Control - Next.js & Nuxt alternative for unprecedented flexibility and dependability.

14 lines (13 loc) 317 B
import { isPlainObject } from './isPlainObject.js'; export { isObjectWithKeys }; function isObjectWithKeys(obj, keys) { if (!isPlainObject(obj)) { return false; } for (const key of Object.keys(obj)) { if (!keys.includes(key)) { return false; } } return true; }