I want to write a custom ParseConfigHost that uses a custom file system.
To implement ParseConfigHost.readDirectory I need to duplicate the whole logic of ts.matchFiles (in core.ts). Alternatively I can use ts.matchFiles directly although it is not exposed through the type declarations.
I propose to add an optional parameter getFileSystemEntries to ts.sys.readDirectory that is then passed to ts.matchFiles and falls back to getAccessibleFileSystemEntries if not provided.
That means the declaration of DirectoryStructureHost.readDirectory needs to be changed, too.
Alternatively you could just expose ts.matchFiles.
I want to write a custom
ParseConfigHostthat uses a custom file system.To implement
ParseConfigHost.readDirectoryI need to duplicate the whole logic ofts.matchFiles(in core.ts). Alternatively I can usets.matchFilesdirectly although it is not exposed through the type declarations.I propose to add an optional parameter
getFileSystemEntriestots.sys.readDirectorythat is then passed tots.matchFilesand falls back togetAccessibleFileSystemEntriesif not provided.That means the declaration of
DirectoryStructureHost.readDirectoryneeds to be changed, too.Alternatively you could just expose
ts.matchFiles.