Skip to main content

Module FileReadAlias

Module FileReadAlias 

Source
Expand description

Cocoon legacy aliases: openDocument, readFile, stat - short-hand routes used by Cocoon’s Effect-TS Workspace + FileSystem services before the canonical FileSystem.* naming was established. Backed by the same FileSystemReader provider.

Functions§

CreateEffect
StripFileUriScheme 🔒
Strip a leading file:// (or file:///) scheme from the incoming path. Mirrors the helper in FileSystem.rs; inlined here to avoid a cross-module dependency on a private function in a sibling module. Cocoon sends full URIs like file:///<home>/.land/extensions/... through the legacy openDocument/readFile/stat routes; without stripping, PathBuf roots at the literal scheme string and every read 404s.