Skip to content

Conversation

@timreichen
Copy link
Contributor

This PR removes the tag, anchor, kind and result class properties in LoaderState and passes a State object to methods that change these properties.
It also makes read*() methods return a State to which automatically entangles lots of nested if/else statements.

This reduces the code complexity massively because these properties are changed recursively and sometimes also backtracked which makes the code very hard to follow and methods not
This also opens the door to reduce the code further in future PRs because it makes redundant code and simplifications obvious.

@timreichen timreichen requested a review from kt3k as a code owner December 19, 2025 08:21
@github-actions github-actions bot added the yaml label Dec 19, 2025
@codecov
Copy link

codecov bot commented Dec 19, 2025

Codecov Report

❌ Patch coverage is 82.91815% with 48 lines in your changes missing coverage. Please review.
✅ Project coverage is 94.12%. Comparing base (6ee055f) to head (0a3f23d).

Files with missing lines Patch % Lines
yaml/_loader_state.ts 82.91% 46 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6902      +/-   ##
==========================================
- Coverage   94.14%   94.12%   -0.02%     
==========================================
  Files         582      582              
  Lines       42750    42808      +58     
  Branches     6807     6825      +18     
==========================================
+ Hits        40245    40292      +47     
- Misses       2455     2467      +12     
+ Partials       50       49       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@timreichen timreichen marked this pull request as draft December 21, 2025 17:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant