mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-11 20:40:20 +00:00
Fixup for "node" types, fs.createReadStream and fs.createWriteStream functions.
This commit is contained in:
Vendored
+4
-3
@@ -2497,6 +2497,7 @@ declare module "dgram" {
|
||||
declare module "fs" {
|
||||
import * as stream from "stream";
|
||||
import * as events from "events";
|
||||
import * as url from "url";
|
||||
|
||||
interface Stats {
|
||||
isFile(): boolean;
|
||||
@@ -2975,7 +2976,7 @@ declare module "fs" {
|
||||
export function access(path: string | Buffer, mode: number, callback: (err: NodeJS.ErrnoException) => void): void;
|
||||
/** Synchronous version of fs.access. This throws if any accessibility checks fail, and does nothing otherwise. */
|
||||
export function accessSync(path: string | Buffer, mode?: number): void;
|
||||
export function createReadStream(path: string | Buffer, options?: {
|
||||
export function createReadStream(path: string | Buffer | url.URL, options?: string | {
|
||||
flags?: string;
|
||||
encoding?: string;
|
||||
fd?: number;
|
||||
@@ -2984,9 +2985,9 @@ declare module "fs" {
|
||||
start?: number;
|
||||
end?: number;
|
||||
}): ReadStream;
|
||||
export function createWriteStream(path: string | Buffer, options?: {
|
||||
export function createWriteStream(path: string | Buffer | url.URL, options?: string | {
|
||||
flags?: string;
|
||||
encoding?: string;
|
||||
defaultEncoding?: string;
|
||||
fd?: number;
|
||||
mode?: number;
|
||||
autoClose?: boolean;
|
||||
|
||||
Reference in New Issue
Block a user