diff --git a/packages/proto-loader/src/index.ts b/packages/proto-loader/src/index.ts index a407e005..563f58f5 100644 --- a/packages/proto-loader/src/index.ts +++ b/packages/proto-loader/src/index.ts @@ -270,8 +270,8 @@ function addIncludePathResolver(root: Protobuf.Root, includePaths: string[]) { /** * Load a .proto file with the specified options. - * @param filename The file path to load. Can be an absolute path or relative to - * an include path. + * @param filename One or multiple file paths to load. Can be an absolute path + * or relative to an include path. * @param options.keepCase Preserve field names. The default is to change them * to camel case. * @param options.longs The type that should be used to represent `long` values. @@ -293,7 +293,7 @@ function addIncludePathResolver(root: Protobuf.Root, includePaths: string[]) { * @param options.includeDirs Paths to search for imported `.proto` files. */ export function load( - filename: string, options?: Options): Promise { + filename: string | string[], options?: Options): Promise { const root: Protobuf.Root = new Protobuf.Root(); options = options || {}; if (!!options.includeDirs) { @@ -310,7 +310,7 @@ export function load( } export function loadSync( - filename: string, options?: Options): PackageDefinition { + filename: string | string[], options?: Options): PackageDefinition { const root: Protobuf.Root = new Protobuf.Root(); options = options || {}; if (!!options.includeDirs) {