nodejs / readable-stream

Node-core streams for userland
https://nodejs.org/api/stream.html
Other
1.03k stars 229 forks source link

@types/readable-stream says not to use Duplex.from #534

Closed 10xLaCroixDrinker closed 8 months ago

10xLaCroixDrinker commented 8 months ago

When Node 12.5 was released, Duplex.from was marked deprecated in @types/readable-stream, with the note "This is a dummy function required to retain type compatibility to node." This doesn't seem to be the case anymore. Can we remove the deprecated tag?

@types/readable-stream/index.d.ts#L279-L284

    class Duplex extends _Writable implements _IDuplex, /*extends*/ _Readable, Duplex {
        /**
         * This is a dummy function required to retain type compatibility to node.
         * @deprecated DO NOT USE
         */
        static from(source: any): any;
mcollina commented 8 months ago

You'll need to send a PR to definitelytyped, those types are not part of the nodejs project