Skip to content

withoutLeadingSlash

Usage

js
import { withoutLeadingSlash } from '@studiometa/js-toolkit/utils';

withoutLeadingSlash('/string'); // "string"
withoutLeadingSlash('string'); // "string"

Parameters

  • string (string): The string to modify.

Return value

  • string: The modified string.

MIT Licensed