Skip to main content

core.ensurenoleadingslash

Home > @medplum/core > ensureNoLeadingSlash

ensureNoLeadingSlash() function

Ensures the given URL has no leading slash.

Signature:

export declare function ensureNoLeadingSlash(url: string): string;

Parameters

Parameter

Type

Description

url

string

The URL to ensure has no leading slash.

Returns:

string

The URL string with no slash.