addLeadingSlash
addLeadingSlash(
text):string
Defined in: packages/core/src/utils.ts:107
Ensures a string starts with a /, prepending one if it is absent.
Parameters
Section titled “Parameters”string
The path string to normalise.
Returns
Section titled “Returns”string
The path with a guaranteed leading slash (e.g. "admin" → "/admin").