Skip to content

nsuite v2.2.1


nsuite / getFilePath

Function: getFilePath()

getFilePath(metaUrl): string

Defined in: UtilsPath.ts:21

Converts a file URL to a file path.

Parameters

metaUrl

string

The file URL to convert.

Returns

string

The file path corresponding to the given file URL.

Example

ts
import { getFilePath } from "nsuite";
const __filename = getFilePath(import.meta.url);

Released under the Apache-2.0 License.