### Callable

- readdir(path: PathLike, options: object | BufferEncoding | undefined | null, callback: function): void
- readdir(path: PathLike, options: object | "buffer", callback: function): void
- readdir(path: PathLike, options: object | string | undefined | null, callback: function): void
- readdir(path: PathLike, callback: function): void
- readdir(path: PathLike, options: object, callback: function): void

- - Defined in node_modules/@types/node/fs.d.ts:814

  Asynchronous readdir(3) - read a directory.

  #### Parameters

  - ##### path: PathLike

    A path to a file. If a URL is provided, it must use the `file:` protocol.

  - ##### options: object | BufferEncoding | undefined | null

    The encoding (or an object specifying the encoding), used as the encoding of the result. If not provided, `'utf8'` is used.

  - ##### callback: function

    - - (err: ErrnoException, files: string[]): void

      - #### Parameters

        - ##### err: ErrnoException

        - ##### files: string[]

        #### Returns void

- - Defined in node_modules/@types/node/fs.d.ts:825

  Asynchronous readdir(3) - read a directory.

  #### Parameters

  - ##### path: PathLike

    A path to a file. If a URL is provided, it must use the `file:` protocol.

  - ##### options: object | "buffer"

    The encoding (or an object specifying the encoding), used as the encoding of the result. If not provided, `'utf8'` is used.

  - ##### callback: function

    - - (err: ErrnoException, files: Buffer[]): void

      - #### Parameters

        - ##### err: ErrnoException

        - ##### files: Buffer[]

        #### Returns void

- - Defined in node_modules/@types/node/fs.d.ts:832

  Asynchronous readdir(3) - read a directory.

  #### Parameters

  - ##### path: PathLike

    A path to a file. If a URL is provided, it must use the `file:` protocol.

  - ##### options: object | string | undefined | null

    The encoding (or an object specifying the encoding), used as the encoding of the result. If not provided, `'utf8'` is used.

  - ##### callback: function

    - - (err: ErrnoException, files: string[] | Buffer[]): void

      - #### Parameters

        - ##### err: ErrnoException

        - ##### files: string[] | Buffer[]

        #### Returns void

- - Defined in node_modules/@types/node/fs.d.ts:842

  Asynchronous readdir(3) - read a directory.

  #### Parameters

  - ##### path: PathLike

    A path to a file. If a URL is provided, it must use the `file:` protocol.

  - ##### callback: function

    - - (err: ErrnoException, files: string[]): void

      - #### Parameters

        - ##### err: ErrnoException

        - ##### files: string[]

        #### Returns void

- - Defined in node_modules/@types/node/fs.d.ts:849

  Asynchronous readdir(3) - read a directory.

  #### Parameters

  - ##### path: PathLike

    A path to a file. If a URL is provided, it must use the `file:` protocol.

  - ##### options: object

    If called with `withFileTypes: true` the result data will be an array of Dirent.

    - ##### withFileTypes: true

  - ##### callback: function

    - - (err: ErrnoException, files: Dirent[]): void

      - #### Parameters

        - ##### err: ErrnoException

        - ##### files: Dirent[]

        #### Returns void

## Index

### Functions

- __promisify__

## Functions

### __promisify__

- __promisify__(path: PathLike, options?: object | BufferEncoding | null): Promise<string[]>
- __promisify__(path: PathLike, options: "buffer" | object): Promise<Buffer[]>
- __promisify__(path: PathLike, options?: object | string | null): Promise<string[] | Buffer[]>
- __promisify__(path: PathLike, options: object): Promise<Dirent[]>

- - Defined in node_modules/@types/node/fs.d.ts:858

  Asynchronous readdir(3) - read a directory.

  #### Parameters

  - ##### path: PathLike

    A path to a file. If a URL is provided, it must use the `file:` protocol.

  - ##### Optional options: object | BufferEncoding | null

    The encoding (or an object specifying the encoding), used as the encoding of the result. If not provided, `'utf8'` is used.

  #### Returns Promise<string[]>

- - Defined in node_modules/@types/node/fs.d.ts:865

  Asynchronous readdir(3) - read a directory.

  #### Parameters

  - ##### path: PathLike

    A path to a file. If a URL is provided, it must use the `file:` protocol.

  - ##### options: "buffer" | object

    The encoding (or an object specifying the encoding), used as the encoding of the result. If not provided, `'utf8'` is used.

  #### Returns Promise<Buffer[]>

- - Defined in node_modules/@types/node/fs.d.ts:872

  Asynchronous readdir(3) - read a directory.

  #### Parameters

  - ##### path: PathLike

    A path to a file. If a URL is provided, it must use the `file:` protocol.

  - ##### Optional options: object | string | null

    The encoding (or an object specifying the encoding), used as the encoding of the result. If not provided, `'utf8'` is used.

  #### Returns Promise<string[] | Buffer[]>

- - Defined in node_modules/@types/node/fs.d.ts:879

  Asynchronous readdir(3) - read a directory.

  #### Parameters

  - ##### path: PathLike

    A path to a file. If a URL is provided, it must use the `file:` protocol.

  - ##### options: object

    If called with `withFileTypes: true` the result data will be an array of Dirent

    - ##### withFileTypes: true

  #### Returns Promise<Dirent[]>

Generated using TypeDoc