Skip to main content
The Deno 2 Release Candidate is here
Learn more
method CustomItemService.prototype.getOrGenerateIdForItem
import { CustomItemService } from "https://deno.land/x/sptaki@1.2.0/services/mod.ts";

If the id provided is an empty string, return a randomly generated guid, otherwise return the newId parameter

Parameters

newId: string

id supplied to code

Returns

string

item id