Skip to content

OverExposureFileSystem

The subset of file-system operations the language-service host needs. Injecting this (rather than always using typescript’s sys) lets tests drive the analyzer against in-memory sources with no real file-system access.

Import:

import type { OverExposureFileSystem } from 'obsidian-dev-utils/script-utils/linters/over-exposure';

Signature:

export interface OverExposureFileSystem

Methods

MethodReturnsDescription
directoryExists(this, path)boolean
fileExists(this, path)boolean
getCurrentDirectory(this)string
getDirectories(this, path)string[]
readDirectory(this, path, extensions?, exclude?, include?, depth?)string[]
readFile(this, path)string | undefined

Links to this page: