Skip to content

Refactor config propagation #46

@xseman

Description

@xseman

related #45 (comment)

Right now resolve() rely on getConfig() (https://github.com/Eywek/typoa/blob/main/src/resolve.ts#L129) to access config, which creates an implicit dependency that's hard to track.

The ideal implementation is to propagate config down the function stack. Passing it around isn't perfect, but it's simple and explicit. If that feels too noisy, we can use something lightweight like async_context to handle this more elegantly without exposing global state or relying on hidden config lookups.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions