Skip to content

Function: usernameFromName() ​

ts
function usernameFromName(name): string;

Defined in: guid.ts:52

A username suggested by a name such as "Rain Bot": spaces become underscores, accents are dropped and other characters a username cannot hold are removed ("Rain_Bot"). Empty when nothing usable is left. Not checked for being free.

Parameters ​

ParameterType
namestring

Returns ​

string

Released under the GNU Affero General Public License v3.0.