import { LogService } from '../services/log/log.ts'; type Dependency = new (services: Services) => T; class Services { #instances = new Map, unknown>(); public get log() { return this.get(LogService); } get = (dependency: Dependency): T => { if (!this.#instances.has(dependency)) { this.#instances.set(dependency, new dependency(this)); } return this.#instances.get(dependency) as T; }; } export { Services };