Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/web_bson/src/objectid.ts>ObjectId.generate

web_bson is a fork from mongodb/js-bson
Very Popular
Go to Latest
method ObjectId.generate
import { ObjectId } from "https://deno.land/x/web_bson@v0.2.4/src/objectid.ts";

Generate a 12 byte id buffer used in ObjectId's

Parameters

optional
time: number
  • pass in a second based timestamp.

Returns

Uint8Array