normalizePath
Normalizes a path so it can be used with the vault. The mock only turns backslashes into forward slashes, collapses repeated slashes and strips a leading or trailing slash.
Import:
import { normalizePath } from 'obsidian-test-mocks/obsidian';Signature:
function normalizePath(path: string): stringParameters:
| Parameter | Type | Description |
|---|---|---|
path |
string | The path to normalize. |
Returns: string — The normalized path.