thanks naku
This commit is contained in:
parent
5af2762e12
commit
fbe2222d1b
|
@ -3,7 +3,9 @@ import * as Yup from "yup";
|
||||||
const REQUIRED = "Required.";
|
const REQUIRED = "Required.";
|
||||||
const USERNAME = Yup.string()
|
const USERNAME = Yup.string()
|
||||||
.required(REQUIRED)
|
.required(REQUIRED)
|
||||||
.min(1, "Username is too short.");
|
.min(1, "Username is too short.")
|
||||||
|
.matches(/^[a-z0-9]+$/, "Username must be lowercase letters and numbers.");
|
||||||
|
|
||||||
const DISPLAY_NAME = Yup.string()
|
const DISPLAY_NAME = Yup.string()
|
||||||
.required(REQUIRED)
|
.required(REQUIRED)
|
||||||
.min(1, "Display name is too short.");
|
.min(1, "Display name is too short.");
|
||||||
|
|
Loading…
Reference in New Issue