Comments (5)
Yes, just use stream.pause()
for standard readable streams these days. That didn't exist in 2010 when this module was made
from pause.
I thought as much; ran into a reference to pause
when I was reading the source to passport. Just wanted to make sure I wasn't crazy. :)
from pause.
Yep. It's certainly possible that it is useful still if there is something that emits data events but implements no way to pause them (of course without the thing allowing pause there is no backpressure as you observed). I don't think that is really the case these days, though. Passport has been around a very long time, so maybe it's just using this from it's own legacy roots, haha.
from pause.
Yeah, it's old code, and thankfully hidden behind an undocumented switch.
I've been writing in node since the 0.6 days. It still feels weird that Node 4 is end-of-life, and I can remove it from my travis.yml files, to be honest. :P
from pause.
Oh, haha. I took a look at the original PR that added it and it was around when 0.10 and streams2 came out. Looks like they rather have people use node 0.10+ than the switch anyway, which is probably why it's undocumented.
It's funny the only reason I took over this module was to make a release because of that npm change where it would warn on installing any package that didn't have a license defined in package.json haha.
from pause.
Related Issues (4)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pause.