web: Clean up browser-only module imports that crash WebDriverIO. (#14330)

* web: Clean up browser-only module imports that crash WebDriverIO.

* web: Clarify slug format output.
This commit is contained in:
Teffen Ellis
2025-05-03 02:04:05 +02:00
committed by GitHub
parent 70d60c7ab2
commit f70635c295
65 changed files with 278 additions and 372 deletions

View File

@ -25,10 +25,3 @@ export function randomId() {
return (c == "x" ? r : (r & 0x3) | 0x8).toString(16);
});
}
export function convertToSlug(text: string) {
return text
.toLowerCase()
.replace(/ /g, "-")
.replace(/[^\w-]+/g, "");
}