export function getLanguageFromURL(pathname: string) { const langCodeMatch = pathname.match(/\/([a-z]{2}-?[A-Z]{0,2})\//); return langCodeMatch ? langCodeMatch[1] : 'en'; } /** Remove \ and / from beginning of string */ export function removeLeadingSlash(path: string) { return path.replace(/^[/\\]+/, ''); } /** Remove \ and / from end of string */ export function removeTrailingSlash(path: string) { return path.replace(/[/\\]+$/, ''); } ass='logo' rowspan='2'>cgit logo index : astro
Unnamed repository; edit this file 'description' to name the repository.
aboutsummaryrefslogtreecommitdiff
path: root/examples/portfolio/.stackblitzrc (unfollow)
AgeCommit message (Expand)AuthorFilesLines
2022-05-11Fix APIRoute type (#3344)Gravatar Matthew Phillips 3-11/+8
2022-05-11[create-astro] Finalize developer experience... with gradients 🚀 (#3313)Gravatar Ben Holmes 5-23/+123