Repository navigation
Fix weekly update build failure (NodeRange) and apply this week's data refresh - #37
Merged
Merged
Conversation
@webref/idl 3.87.0 picks up the DOM spec change that moves startContainer/endContainer from AbstractRange into a new intermediate NodeRange interface, which Range and StaticRange now extend. No browser ships NodeRange and BCD has no entry for it, so the BCD filter drops it, leaving Range/StaticRange extending a missing type (TS2304) and losing both container members. Patch dom.kdl to keep the shipped shape: re-add the members to AbstractRange (where BCD and MDN still track them), point Range and StaticRange back at AbstractRange, and remove NodeRange explicitly so the Baseline cuts' reference closure doesn't keep it as an orphan shell. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KZB12ZXHat7nYEsQcJxGmd
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KZB12ZXHat7nYEsQcJxGmd
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Supersedes #35. Like #32, this carries the automated weekly refresh commit unchanged, plus a fix for the build failure it introduces.
Problem
The
testcheck on #35 fails:@webref/idl3.87.0 brings in a DOM spec change. A new intermediate interfaceNodeRange : AbstractRangenow holdsstartContainer/endContainer, andRangeandStaticRangeextend it. No browser shipsNodeRange, and BCD (8.1.9) has noapi.NodeRangeentry; it still tracks the two members underapi.AbstractRange. So the BCD filter dropsNodeRange. That leavesRange/StaticRangeextending a missing type and silently dropsstartContainer/endContainerfrom both. #35 would have published that regression to every@baseline-types/dom-*package.Fix
A patch in
inputfiles/patches/dom.kdlthat keeps the shape browsers actually ship:startContainer/endContainertoAbstractRange(MDN descriptions still resolve frommdn.json);RangeandStaticRangeextendAbstractRangeagain;removals { interface NodeRange }. Baseline cuts need this:applyReferenceClosureruns before patches, still seesRange : NodeRange, and would otherwise keepNodeRangeas an unused type-only interface in every cut.The patch has to be removed once browsers and BCD ship
NodeRange. This is tracked in #36, and the patch comment links to it.Verification
npm testpasses.AbstractRangeinbaselines/dom.generated.d.ts(and the ts5.5/5.6/5.9 variants) matches the output before the update, apart from one upstream MDN wording change in theendOffsetdescription.2022,2023,2024,2025,newly-available,widely-available):NodeRangeanywhere;AbstractRangehas both container members, andRange/StaticRangeextend it;dom.generated.d.tsandwebworker.generated.d.tstype-check on their own;NodeRangeremoval changes nothing else in the cuts.Release
Merging triggers Release baseline packages, which republishes whichever
@baseline-types/dom-<target>packages changed relative to npmlatest. Once this is merged, #35 can be closed.Generated by Claude Code