Repository navigation
docs: narrow clipboardItem.getType() return type from its MIME type - #54343
Merged
Merged
Conversation
…54300) * docs: narrow clipboardItem.getType() return type from its MIME type Type getType() with a generic MIME type parameter and a conditional return type so a literal `electron application/bookmark` resolves to a ClipboardBookmark, any other literal MIME type resolves to a Blob, and a non-literal string still resolves to the union. Adds ts-smoke cases for all three and drops the now-unneeded `instanceof Blob` check from the `text/uri-list` example. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01HmVsAQiHawruFHijTtkzV9 * build: bump @electron/docs-parser to 3.0.2 Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01HmVsAQiHawruFHijTtkzV9 --------- Co-authored-by: Claude <[email protected]> (cherry picked from commit 70d678d) Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01A6qgQ8Q6Q5rwKtmambSd9V
4 of 5 tasks
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
|
All alerts resolved. Learn more about Socket for GitHub. This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored. Ignoring alerts on:
|
MarshallOfSound
approved these changes
Sep 25, 2026
Member
|
@SocketSecurity ignore npm/@electron/[email protected] |
MarshallOfSound
enabled auto-merge (squash)
September 25, 2026 09:02
codebytere
approved these changes
Sep 25, 2026
|
Release Notes Persisted
|
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.
Requested by Samuel Attard · Slack thread
Description of Change
Backport of #54300
See that PR for details. This backport also bumps
@electron/docs-parserto 3.0.2.Checklist
npm testpasses🤖 Generated with Claude Code
https://claude.ai/code/session_01A6qgQ8Q6Q5rwKtmambSd9V
Release Notes
Notes: Improved TypeScript types for
clipboardItem.getType()to narrow by MIME type.