UNPKG

@playt/client

Version:
15 lines (13 loc) 246 B
import slugify from "slugify"; slugify.extend({ "/": "-", ".": "-", ":": "-", }); export const normalizeEnvironmentName = (url: URL) => { return slugify(url.origin + url.pathname, { lower: true, strict: true, replacement: "-", }); };