Creates a function for generating unique names for Adapt Elements.
export declare function makeResourceName(invalidChars: RegExp, maxLen: number, sep?: string): (elemKey: string, elemID: string, deployID: string) => string;
|invalidChars||A regular expression that matches all invalid characters that should NOT be included in the resulting name. Must have the global flag set. For example, if only alphabetic characters and dashes are allowed, set |
|maxLen||The maximum allowed length of name that should be generated.|
|sep||The separator string to be used between they key and the hash.|
(elemKey: string, elemID: string, deployID: string) => string
The unique names are unique by probability, based on a SHA256 hash. They are are made up of:
The Element's key, with any invalid characters removed.
A separator character (or string)
A portion of the SHA256 hash of the Element's ID and the deployID.