UNPKG
@produck/json-index-archive
Version:
latest (0.1.3)
0.1.3
0.1.2
0.1.1
0.1.0
@produck/json-index-archive
/
src
/
FileSystem
/
Implement
/
CreateReadStream.mjs
10 lines
(8 loc)
•
280 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
import { ReadStream }
from
'../ReadStream.mjs'
;
/**
@param
{import('../Constructor.mjs').FileSystem} self */
export
default
(
self
, pathname, ...options) => {
return
new
ReadStream
({ path: pathname, fetchFileHandle:
async
() => await
self
.
open
(pathname), }, ...options); };