Skip to main content
Module

x/mongo/deps.ts>calculateObjectSize

MongoDB driver for Deno
Extremely Popular
Go to Latest
function calculateObjectSize
import { calculateObjectSize } from "https://deno.land/x/mongo@v0.31.2/deps.ts";

Calculate the bson size for a passed in Javascript object.

Parameters

object: Document
  • the Javascript object to calculate the BSON byte size for

Returns

number

size of BSON object in bytes