Skip to main content

browser-tracker.setuserid

Home > @snowplow/browser-tracker > setUserId

setUserId() function

Set the business-defined user ID for this user.

Signature:
declare function setUserId(userId?: string | null, trackers?: Array<string>): void;

Parameters

ParameterTypeDescription
userIdstring | nullThe business-defined user ID
trackersArray<string>The tracker identifiers which will be configured
Returns:

void