summary refs log tree commit diff
path: root/src/util/plugin/Plugin.ts
blob: ee4fd95cb28ba5912cbaf4e65d9f25a45629f3dc (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
import { TypedEventEmitter } from "@fosscord/util";
import EventEmitter from "events";

type PluginEvents = {
	error: (error: Error | unknown) => void;
	loaded: () => void;
};

export class Plugin extends (EventEmitter as new () => TypedEventEmitter<PluginEvents>) {
	async init() {
		// insert default config into database?
	}
}