Skip to content
This repository was archived by the owner on Jul 27, 2021. It is now read-only.
/ file Public archive

Web API compatible File implementation for node

License

Notifications You must be signed in to change notification settings

web-std/file

Folders and files

NameName
Last commit message
Last commit date

Latest commit

d0d75ad · Jul 27, 2021

History

11 Commits
Jul 20, 2020
Jul 20, 2020
Jul 20, 2020
Jul 20, 2020
Jul 20, 2020
Jul 20, 2020
Jul 27, 2021
Jul 20, 2020
Jul 20, 2020
Jul 20, 2020
Jul 20, 2020
Jul 27, 2021

Repository files navigation

web-file

Status

Deprecated: This library was superseeded by @web-std/file. Please use that library instead.

Node.js CI package downloads styled with prettier

Web API compatible File for nodejs.

Usage

import { File, Blob } from "web-file-polyfill"
const file = new File(["hello", new TextEncoder().encode("world")], "hello")
for await (const chunk of blob.stream()) {
  console.log(chunk)
}

Usage from Typescript

This library makes use of typescript using JSDOC annotations and also generates type difinitions along with typed definition maps. So you should be able to get all the type innference out of the box.

Install

npm install web-file-polyfill