Skip to content

getFolderName

Gets the folder name from the import(dot)meta(dot)url, converting it to a POSIX-style path.

Import:

import { getFolderName } from 'obsidian-dev-utils/path';

Signature:

function getFolderName(importMetaUrl: string): string

Parameters:

ParameterTypeDescription
importMetaUrlstringThe import(dot)meta(dot)url from which to extract the folder name.

Returns: string — The POSIX-style folder name.