0.3.1
A deno module for downloading files as a readable stream, which allows for flexible targets and progress display
Attributes
Includes Deno configuration
Repository
Current version released
2 years ago
Downstream
CAUTION: HIGHLY EXPERIMENTAL AT THE MOMENT!
A deno module for downloading files in a streaming fashion.
The base of this module is downstream.ts
, which queries the file and returns the ReadableStream,
as well as a progress Stream in percent (from 0 to 100) (not included yet).
This base function is then augmented with various utility functions for writing this stream into a file or passing it to other streams, as I see fit.
Folder Structure
.vscode
= A folder,- containing a
settings.json
which activates the deno language server for this workspace - containing a
extensions.json
with recommended vscode extensions for this workspace
- containing a
example
= A folder, containing entry deno files for demonstrating the modules functionalities- contains
main.ts
- the default file for examples
- contains
dependencies
= A folder, including dependency re-exportsmy_module_part
= A folder containing more source files which are exported bymod.ts
- Hint: you may create multiple of them to structure your module.
.gitignore
= A normal gitingore filedeno.json
- a config file for the deno cli- includes tasks (a.k.a aliases for long commands) with
deno task
- includes tasks (a.k.a aliases for long commands) with
LICENSE
mod.ts
= the entrypoint for this deno module, which exports all functionality of this moduleReadme.md
= A normal Readme file
Running examples
see tasks
property in deno.json
Run each key there with deno task <task-key>
Useful Links
- Big test files for testing these download functions: https://testfiledownload.com/
- How to pipe streams in deno: https://deno.land/manual/examples/fetch_data#files-and-streams
- Guide to Web Streams: https://web.dev/streams/#creating-a-transform-stream