Module
Pipes.Node.FS
- Package
- purescript-node-stream-pipes
- Repository
- cakekindel/purescript-node-stream-pipes
#write' Source
write' :: forall r trash m. Union r trash WriteStreamOptions => MonadAff m => MonadThrow Error m => Record r -> FilePath -> Consumer (Maybe Buffer) m Unit
Creates a fs.Writable
stream for the file
at the given path.
Writing Nothing
to this pipe will close the stream.
See Pipes.Node.Stream.withEOS
for converting Producer a
into Producer (Maybe a)
, emitting Nothing
before exiting.
#read' Source
read' :: forall r trash m. Union r trash ReadStreamOptions => MonadAff m => MonadThrow Error m => Record r -> FilePath -> Producer (Maybe Buffer) m Unit
Creates a fs.Readable
stream for the file at the given path.
Emits Nothing
before closing. To opt out of this behavior,
use Pipes.Node.Stream.withoutEOS
or Pipes.Node.Stream.unEOS
.