#FileLoader Class

Lists Event and Commands by reading the folder.


#Import

import { FileLoader } from 'discordkit';

#Constructor

new FileLoader<T>(path: string);

#Properties

List of files in the folder.
Type: T[]


The time when the folder was started to be read.
Type: number


#Events

It is triggered when an error occurs while reading the folder.

ParameterTypeDescription
errErrorError.

It is triggered when the process of reading the folder is finished.

ParameterTypeDescription
timenumberReading time.

It is triggered when a file is read.

ParameterTypeDescription
fileTDefault export of file.