Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/somefn/js/obj.ts>isEmptyObj

some functions for deno
Go to Latest
function isEmptyObj
import { isEmptyObj } from "https://deno.land/x/somefn@v0.27.0/js/obj.ts";

判断对象是否为空对象

JSON.stringify(obj) === '{}' 效果一致.

Parameters

obj: Record<string, unknown>

Returns

boolean

是否为空对象, true 为 空, false 为非空