@bendyline/docblocks
v1.0.0
Published
Core data structures and filesystem abstractions for DocBlocks
Maintainers
Readme
@bendyline/docblocks
Core data structures and filesystem abstractions for DocBlocks.
Installation
npm install @bendyline/docblocksExports
The package provides two main modules:
Filesystem (@bendyline/docblocks/filesystem)
Pluggable filesystem abstraction layer with multiple storage backends.
FileSystemProvider— Abstract interface for filesystem operations (readFile,writeFile,readDirectory,delete,rename,createDirectory,stat)IndexedDBFileSystemProvider— Browser-based persistent storage using IndexedDBNativeFileSystemProvider— Native filesystem access via the File System Access APIIndexedDBContentContainer— Content management layer for media and document storage
import { IndexedDBFileSystemProvider } from '@bendyline/docblocks/filesystem';
const fs = new IndexedDBFileSystemProvider('my-workspace');
await fs.writeFile('/doc.md', '# Hello');
const content = await fs.readFile('/doc.md');Workspace (@bendyline/docblocks/workspace)
Workspace management utilities for organizing document projects.
listWorkspaces— List all known workspacesgetWorkspace/saveWorkspace/removeWorkspace— CRUD operationstouchWorkspace— Update last-opened timestampensureDefaultWorkspace— Create a default workspace if none exist
import { listWorkspaces, ensureDefaultWorkspace } from '@bendyline/docblocks/workspace';
const workspaces = await listWorkspaces();License
MIT
