From a834f70fde604d7be4a2a58e6c5e5ab3fd323048 Mon Sep 17 00:00:00 2001 From: Klaus Meinhardt Date: Mon, 7 May 2018 18:15:36 +0200 Subject: [PATCH] resolve: use ReadonlyArray for options (#25544) --- types/resolve/index.d.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/types/resolve/index.d.ts b/types/resolve/index.d.ts index af32bf4097..a3fb1f4f46 100644 --- a/types/resolve/index.d.ts +++ b/types/resolve/index.d.ts @@ -73,15 +73,15 @@ declare namespace resolve { /** package.json data applicable to the module being loaded */ package?: any; /** array of file extensions to search in order (defaults to ['.js']) */ - extensions?: string | string[]; + extensions?: string | ReadonlyArray; /** transform the parsed package.json contents before looking at the "main" field */ packageFilter?: (pkg: any, pkgfile: string) => any; /** transform a path within a package */ pathFilter?: (pkg: any, path: string, relativePath: string) => string; /** require.paths array to use if nothing is found on the normal node_modules recursive walk (probably don't use this) */ - paths?: string | string[]; + paths?: string | ReadonlyArray; /** directory (or directories) in which to recursively look for modules. (default to 'node_modules') */ - moduleDirectory?: string | string[] + moduleDirectory?: string | ReadonlyArray /** * if true, doesn't resolve `basedir` to real path before resolving. * This is the way Node resolves dependencies when executed with the --preserve-symlinks flag.