Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@stardazed/streams

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@stardazed/streams - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

dist/sd-streams.umd.js

10

package.json
{
"name": "@stardazed/streams",
"description": "Web Streams implementation / polyfill",
"version": "1.0.1",
"description": "Web Streams implementation",
"version": "1.0.2",
"author": {
"name": "Arthur Langereis"
},
"license": "MIT",
"repository": {

@@ -12,3 +13,4 @@ "type": "git",

},
"main": "dist/sd-streams.esm.js",
"main": "dist/sd-streams.umd.js",
"browser": "dist/sd-streams.esm.js",
"module": "dist/sd-streams.esm.js",

@@ -18,3 +20,3 @@ "types": "dist/sd-streams.d.ts",

"build": "rollup -c",
"prepare": "npm run build"
"prepublishOnly": "npm run build"
},

@@ -21,0 +23,0 @@ "devDependencies": {

57

README.md

@@ -1,6 +0,6 @@

sd-streams
==========
@stardazed/streams
==================
This library provides a full implementation of the web streams standard. It has
no dependencies and can be used as a streams testing bed or polyfill in browsers without
(full) support for the streams standard.
no dependencies and can be used as a streams replacement in browsers without (full)
support for the streams standard or in Node.

@@ -10,8 +10,9 @@ It also provides a full set of TypeScript types for the library as an improvement

### Compliance
This implementation passes all tests (as specified by late June 2018) in the
Compliance
-----------
This implementation passes all tests (as specified by July 2018) in the
[web platform tests](https://github.com/web-platform-tests/wpt/tree/master/streams)
except for the detached buffer tests as explained below.
While this is nice, a number of tests in the suite are aimed mainly at browser engine
This is a good thing, but a number of tests in the suite are aimed mainly at browser engine
internals or ordering of instructions strictly to the letter of the spec.

@@ -22,4 +23,5 @@ This implementation may at any point deviate from certain spec tests for legibility or

### Limitations
While the full streams API is implemented, this library's code lives in the client space
Limitations
-----------
Although the full streams API is implemented, this library's code lives in the client space
and cannot directly be used with other built-in APIs. This includes calling `getReader` on

@@ -30,2 +32,10 @@ the `body` of a `fetch` call, which may either not be implemented at all or return a browser

👉 The [streams fetch adapter](https://github.com/stardazed/sd-streams-fetch-adapter) package
can be used to create modified versions of `fetch` and `Response` to work with this or
any other `ReadableStream` implementation.
👉 The [Stardazed streams polyfill](https://github.com/stardazed/sd-streams-polyfill)
package provides a full replacement for streams, `fetch` and `Response` as a global polyfill.
Use this if you just want a drop-in, make-it-work version of Stardazed streams.
In addition, while the BYOB variant of `ReadableStream` is implemented, buffers are copied

@@ -37,11 +47,28 @@ and not transferred as no browser has implemented detached buffers yet, let alone exposed

------------
**⚠️ Important**: This package is distributed as an ES2015 module and is intended
for use in browsers, not in NodeJS per se. Browser-specific types may be used.
```
npm install @stardazed/streams
pnpm install @stardazed/streams
yarn add @stardazed/streams
```
`npm install @stardazed/streams`<br>
`pnpm install @stardazed/streams`<br>
`yarn add @stardazed/streams`
Usage
-----
In a build system or runtime with module support:
```js
// stream types
import { ReadableStream, WriteStream, TransformStream } from "@stardazed/streams";
// built-in strategies
import { ByteLengthQueuingStrategy, CountQueuingStrategy } from "@stardazed/streams";
```
In pre-modular Node:
```js
// stream types
const { ReadableStream, WriteStream, TransformStream } = require("@stardazed/streams");
// built-in strategies
const { ByteLengthQueuingStrategy, CountQueuingStrategy } = require("@stardazed/streams");
```
See the [Web Streams Standard Specification](https://streams.spec.whatwg.org) for

@@ -48,0 +75,0 @@ documentation, examples, etc.

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc