Skip to content
This repository was archived by the owner on Jul 13, 2020. It is now read-only.
This repository was archived by the owner on Jul 13, 2020. It is now read-only.

Switch to "true" dependency injection #18

@JoshuaKGoldberg

Description

@JoshuaKGoldberg

Right now, stores typically have the following kind of logic:

// ContainerStore.ts
import { ChildStore, IChildStoreDependencies } from "./ChildStore";

export interface IContainerStoreDependencies extends IChildStoreDependencies { /* .. */ }

export class ContainerStore {
    public readonly child = new ChildStore(this.dependencies);
}

This means a lot of stores have really big dependencies typings. It would be more true to the DI way if the child stores were passed into the parents.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions