Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: Reduce cyclic dependencies in src/ #2612

Merged
merged 4 commits into from Jan 23, 2024
Merged

Conversation

claremacrae
Copy link
Collaborator

@claremacrae claremacrae commented Jan 23, 2024

Description

Reduce cyclic dependencies between source files, by:

  • Moving Priority and TaskRegularExpressions out of Task.ts
  • Moving getPrintableSymbol() from StatusRegistryReport.ts to StatusSettingsReport.ts

I decided to version control circular-deps.txt for a while, to keep an eye on any growth of cyclic dependencies. It does have the annoyance that it contains a flickering time measurement, but I'm assuming it's likely only me and @ilandikov who might run it, and we can try and revert any changes if the only difference is from running the tool and getting a differing timing.

The file can be updated with:

yarn run circular-deps-text

And see the similar

yarn run circular-deps-image

Motivation and Context

It's kind of a constant process of trying to simplify code by reducing these dependencies. See #1402 for an earlier attempt.

How has this been tested?

Screenshots (if appropriate)

Before and after:

image

Types of changes

Internal changes:

  • Refactor (prefix: refactor - non-breaking change which only improves the design or structure of existing code, and making no changes to its external behaviour)

Checklist

Terms

@claremacrae claremacrae added the type: internal Only regards development or contributing label Jan 23, 2024
@claremacrae claremacrae merged commit e65dd75 into main Jan 23, 2024
3 checks passed
@claremacrae claremacrae deleted the reduce-cyclic-deps branch January 23, 2024 23:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: internal Only regards development or contributing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant