opfs tools
1.0.0
EN : OPF를 기반으로 구축 된 브라우저에서 실행되는 간단하고 고성능 및 포괄적 인 파일 시스템 API.
CN : i API, 基于 OPFS 构建。
API 문서
기준
OPFS-Tools-Explorer 프로젝트에서 온라인 데모를 경험할 수 있습니다. 
import { file , dir , write } from 'opfs-tools' ;
// --------- Create / Write ---------
await dir ( '/test-dir' ) . create ( ) ; // create a directory
await write ( '/dir/file.txt' , '' ) ; // empty file
await write ( '/dir/fetch-file' , ( await fetch ( '//example.com' ) ) . body ) ;
// inputFile from the input element picked by the user
await write ( '/dir/input-file' , inputFile . stream ( ) ) ;
// For incremental file writes, please refer to the API documentation.
const writer = await file ( '/dir/file' ) . createWriter ( ) ;
// --------- Read ---------
await file ( '/dir/file.txt' ) . text ( ) ;
await file ( '/dir/input-file' ) . arrayBuffer ( ) ;
await file ( '/dir/input-file' ) . stream ( ) ;
// If you want to read file fragments, please refer to the API documentation.
const reader = await file ( '/dir/input-file' ) . createReader ( ) ;
await dir ( '/test-dir' ) . children ( ) ;
// --------- Remove ---------
await dir ( '/test-dir' ) . remove ( ) ;
await file ( '/dir/file.txt' ) . remove ( ) ;
// --------- copyTo / moveTo ---------
await file ( '/dir/file' ) . copyTo ( file ( '/dir/file copy1' ) ) ;
await dir ( '/dir' ) . moveTo ( dir ( '/.Trash' ) ) ;文章 : 웹 web : (opfs 及工具 ∎))) 介绍