René's URL Explorer Experiment


Title: Possible breaking change: assigning array to 1-tuple · Issue #42504 · microsoft/TypeScript · GitHub

Open Graph Title: Possible breaking change: assigning array to 1-tuple · Issue #42504 · microsoft/TypeScript

X Title: Possible breaking change: assigning array to 1-tuple · Issue #42504 · microsoft/TypeScript

Description: Bug Report 🔎 Search Terms dom, tuple, assignability 🕗 Version & Regression Information Repros in 4.2 Beta and nightly This changed between versions 4.1.3 and 4.2 beta Important caveat: The code was originally building against 4.1 and had...

Open Graph Description: Bug Report 🔎 Search Terms dom, tuple, assignability 🕗 Version & Regression Information Repros in 4.2 Beta and nightly This changed between versions 4.1.3 and 4.2 beta Important caveat: The code was...

X Description: Bug Report 🔎 Search Terms dom, tuple, assignability 🕗 Version & Regression Information Repros in 4.2 Beta and nightly This changed between versions 4.1.3 and 4.2 beta Important caveat: The code...

Opengraph URL: https://github.com/microsoft/TypeScript/issues/42504

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Possible breaking change: assigning array to 1-tuple","articleBody":"# Bug Report\r\n\r\n### 🔎 Search Terms\r\n\r\ndom, tuple, assignability\r\n\r\n### 🕗 Version & Regression Information\r\n\r\nRepros in 4.2 Beta and nightly\r\n\r\n- This changed between versions 4.1.3 and 4.2 beta\r\n\r\n**Important caveat:** The code was originally building against 4.1 and had polyfills for types that are in lib.dom.d.ts in 4.2.\r\n\r\n### ⏯ Playground Link\r\n\r\nTS 4.1.3 with polyfills: [Playground](https://www.typescriptlang.org/play?ts=4.1.3#code/JYOwLgpgTgZghgYwgAgEoQM7AF4QPIBGG0AbtAMJwA2VBiA1sgN4BQyyAFBOFMJgFxpMOfEVLQAojwCeAbQC6AGmQB7MVDJRB6LLkLEN0AJSCSK4ABMA3CwC+LFqEixEKHSP3ioUsFGnM2ZCgIOAsVECp-MDgoAHMIMEEJKggAW24wG3Zg0PDI5ARwyHB0BETkABE8AFlSsHRQvAjpG3tHcGh4JCFdUQNNAPY1fogOaLiEpJT08BNkM0ss5ABXEGHxMZj48uS0jLmF60CLYAxCkBAIMo4D8yO2p07XHo91TQBJEAxokG7WbJCYWayAADlAVGAIdIQRBtMI9G9oEtLgB3TgIai0Bhw3qeQxQSg0OgIehzdwIkZQVoOCxXKgxFApMAvCleHGvSmfb5wX4QGztZxdFAAdVAYTR-yCgLy-nJfTZLPl+K5PyQ1JY52+UtxiKgyAAvMhUYq8ZoOBxZBk-PJ2az8T4-AojAaAHyDZBW6R2IxWIA)\r\n\r\nTS 4.2 beta with re-declaration of lib.dom.d.ts interface: [Playground](https://www.typescriptlang.org/play?ts=4.2.0-beta#code/JYOwLgpgTgZghgYwgAgEoQM7AF4QPIBGG0AbtAMJwA2VBiA1sgN4BQyyAFBOFMJgFxpMOfEVLQAojwCeAbQC6AGmQB7MVDJRB6LLkLEN0AJSCSK4ABMA3CwC+LFghUgMYZFGF71m5AF5kIBAA7kK6ogaaHByy3GBQ0vJGfgB8zGzIsfF2RlZAA)\r\n\r\n### 💻 Code\r\n\r\n\u003c!-- Please post the relevant code sample here as well-->\r\n```ts\r\ninterface ResizeObserverCallback {\r\n  (entries: ResizeObserverEntry[], observer: ResizeObserver): void;\r\n}\r\n\r\nconst resizeObserver = new ResizeObserver(([entry]) => {\r\n  entry\r\n});\r\n```\r\n\r\n### 🙁 Actual behavior\r\n\r\n```\r\nArgument of type '([entry]: [any]) => void' is not assignable to parameter of type 'ResizeObserverCallback'.\r\n  Types of parameters '__0' and 'entries' are incompatible.\r\n    Type 'ResizeObserverEntry[]' is not assignable to type '[any]'.\r\n      Target requires 1 element(s) but source may have fewer.(2345)\r\n```\r\n\r\n### 🙂 Expected behavior\r\n\r\nThe fact that the repro depends on re-declaring a dom interface is suspicious, but the re-declaration appears to be identical, so it's not obvious to me why this error would be produced.\r\n\r\nAlso, note that the (as a result of sensible variance reasons), the lambda parameter is listed before the callback parameter on line 2 of the error and the types are in the _opposite_ order on line 3 of the error.  I found this confusing.\r\n","author":{"url":"https://github.com/amcasey","@type":"Person","name":"amcasey"},"datePublished":"2021-01-26T23:58:41Z","url":"https://github.com/microsoft/TypeScript/issues/42504"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:84120c23-b9b8-61df-9d11-481a5ff8d182
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idACA2:4BB79:707244:914664:6B00E3FC
html-safe-nonce2ff701b1d2ed674b8d1b23130afb7e3170e71da97b80379562dcd6eceb04a595
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBQ0EyOjRCQjc5OjcwNzI0NDo5MTQ2NjQ6NkIwMEUzRkMiLCJ2aXNpdG9yX2lkIjoiNTI0ODM0MDQxMjc2MTk1NzM3MiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac94de17548d25e2595d2bfa53ce6ea60012c881ee305c10001db1e4e40f620abf
hovercard-subject-tagissue:794650423
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/microsoft/TypeScript/42504/issue_layout
twitter:imagehttps://opengraph.githubassets.com/f4a4a8351cdc65f9113007fdefaa7c96e5df67fb0495b44ef5ff2f017283bd46/microsoft/TypeScript/issues/42504
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/f4a4a8351cdc65f9113007fdefaa7c96e5df67fb0495b44ef5ff2f017283bd46/microsoft/TypeScript/issues/42504
og:image:altBug Report 🔎 Search Terms dom, tuple, assignability 🕗 Version & Regression Information Repros in 4.2 Beta and nightly This changed between versions 4.1.3 and 4.2 beta Important caveat: The code was...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameamcasey
hostnamegithub.com
expected-hostnamegithub.com
None27088b6977484d0d3321d9a11c907c6d6637b315cfa359ef7952dbf6292f9b14
turbo-cache-controlno-preview
go-importgithub.com/microsoft/TypeScript git https://github.com/microsoft/TypeScript.git
octolytics-dimension-user_id6154722
octolytics-dimension-user_loginmicrosoft
octolytics-dimension-repository_id20929025
octolytics-dimension-repository_nwomicrosoft/TypeScript
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id20929025
octolytics-dimension-repository_network_root_nwomicrosoft/TypeScript
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release624179fb8b88d26ba5bba08894eb60a1c5a1d93d
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/microsoft/TypeScript/issues/42504#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fmicrosoft%2FTypeScript%2Fissues%2F42504
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fmicrosoft%2FTypeScript%2Fissues%2F42504
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=microsoft%2FTypeScript
Reloadhttps://github.com/microsoft/TypeScript/issues/42504
Reloadhttps://github.com/microsoft/TypeScript/issues/42504
Reloadhttps://github.com/microsoft/TypeScript/issues/42504
microsofthttps://github.com/microsoft
TypeScripthttps://github.com/microsoft/TypeScript
Codehttps://github.com/microsoft/TypeScript
Issues5k (5k)https://github.com/microsoft/TypeScript/issues
Pull requests309 (309)https://github.com/microsoft/TypeScript/pulls
Actionshttps://github.com/microsoft/TypeScript/actions
Projectshttps://github.com/microsoft/TypeScript/projects
Wikihttps://github.com/microsoft/TypeScript/wiki
Security and qualityhttps://github.com/microsoft/TypeScript/security
Insightshttps://github.com/microsoft/TypeScript/insights
https://github.com/microsoft/TypeScript
New issuehttps://github.com/login?return_to=https://github.com/microsoft/TypeScript/issues/42504
New issuehttps://github.com/login?return_to=https://github.com/microsoft/TypeScript/issues/42504
#42620https://github.com/microsoft/TypeScript/pull/42620
Possible breaking change: assigning array to 1-tuplehttps://github.com/microsoft/TypeScript/issues/42504#top
#42620https://github.com/microsoft/TypeScript/pull/42620
Working as IntendedThe behavior described is the intended behavior; this is not a bughttps://github.com/microsoft/TypeScript/issues?q=state%3Aopen%20label%3A%22Working%20as%20Intended%22
https://github.com/amcasey
Andrew Casey (amcasey)https://github.com/amcasey
on Jan 26, 2021https://github.com/microsoft/TypeScript/issues/42504#issue-794650423
Playgroundhttps://www.typescriptlang.org/play?ts=4.1.3#code/JYOwLgpgTgZghgYwgAgEoQM7AF4QPIBGG0AbtAMJwA2VBiA1sgN4BQyyAFBOFMJgFxpMOfEVLQAojwCeAbQC6AGmQB7MVDJRB6LLkLEN0AJSCSK4ABMA3CwC+LFqEixEKHSP3ioUsFGnM2ZCgIOAsVECp-MDgoAHMIMEEJKggAW24wG3Zg0PDI5ARwyHB0BETkABE8AFlSsHRQvAjpG3tHcGh4JCFdUQNNAPY1fogOaLiEpJT08BNkM0ss5ABXEGHxMZj48uS0jLmF60CLYAxCkBAIMo4D8yO2p07XHo91TQBJEAxokG7WbJCYWayAADlAVGAIdIQRBtMI9G9oEtLgB3TgIai0Bhw3qeQxQSg0OgIehzdwIkZQVoOCxXKgxFApMAvCleHGvSmfb5wX4QGztZxdFAAdVAYTR-yCgLy-nJfTZLPl+K5PyQ1JY52+UtxiKgyAAvMhUYq8ZoOBxZBk-PJ2az8T4-AojAaAHyDZBW6R2IxWIA
Playgroundhttps://www.typescriptlang.org/play?ts=4.2.0-beta#code/JYOwLgpgTgZghgYwgAgEoQM7AF4QPIBGG0AbtAMJwA2VBiA1sgN4BQyyAFBOFMJgFxpMOfEVLQAojwCeAbQC6AGmQB7MVDJRB6LLkLEN0AJSCSK4ABMA3CwC+LFghUgMYZFGF71m5AF5kIBAA7kK6ogaaHByy3GBQ0vJGfgB8zGzIsfF2RlZAA
https://github.com/amcasey
Andrew Casey (amcasey)https://github.com/amcasey
on Jan 26, 2021https://github.com/microsoft/TypeScript/issues/42504#issuecomment-767909435
Ryan Cavanaugh (@RyanCavanaugh)https://github.com/RyanCavanaugh
https://github.com/weswigham
Wesley Wigham (weswigham)https://github.com/weswigham
on Jan 27, 2021https://github.com/microsoft/TypeScript/issues/42504#issuecomment-767939153
https://github.com/amcasey
Andrew Casey (amcasey)https://github.com/amcasey
on Jan 27, 2021https://github.com/microsoft/TypeScript/issues/42504#issuecomment-767942543
Wesley Wigham (@weswigham)https://github.com/weswigham
https://github.com/weswigham
Wesley Wigham (weswigham)https://github.com/weswigham
on Jan 27, 2021https://github.com/microsoft/TypeScript/issues/42504#issuecomment-767947993
Ryan Cavanaugh (RyanCavanaugh)https://github.com/RyanCavanaugh
Working as IntendedThe behavior described is the intended behavior; this is not a bughttps://github.com/microsoft/TypeScript/issues?q=state%3Aopen%20label%3A%22Working%20as%20Intended%22
on Jan 27, 2021https://github.com/microsoft/TypeScript/issues/42504#event-4257060224
https://github.com/RyanCavanaugh
Ryan Cavanaugh (RyanCavanaugh)https://github.com/RyanCavanaugh
on Jan 27, 2021https://github.com/microsoft/TypeScript/issues/42504#issuecomment-768443749
Andrew Casey (amcasey)https://github.com/amcasey
completedhttps://github.com/microsoft/TypeScript/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
on Jan 27, 2021https://github.com/microsoft/TypeScript/issues/42504#event-4257139249
microsofthttps://github.com/microsoft
on Oct 21, 2025https://github.com/microsoft/TypeScript/issues/42504#event-20417367928
Sign up for freehttps://github.com/signup?return_to=https://github.com/microsoft/TypeScript/issues/42504
Sign in to commenthttps://github.com/login?return_to=https://github.com/microsoft/TypeScript/issues/42504
Working as IntendedThe behavior described is the intended behavior; this is not a bughttps://github.com/microsoft/TypeScript/issues?q=state%3Aopen%20label%3A%22Working%20as%20Intended%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.