UNPKG

@refinedev/core

Version:

Refine is a React meta-framework for building enterprise-level, data-intensive applications rapidly with support for modern UI libraries and headless integrations.

7 lines (6 loc) 169 B
/** * Remove leading and trailing slashes from a route. */ export const removeLeadingTrailingSlashes = (route: string) => { return route.replace(/^\/|\/$/g, ""); };