Skip to content

[web] Remove Clipboard API fallback #157484

Closed

Description

@ditman

The web engine has some logic to be able to copy-paste content from a Flutter app, which is using a now outdated/deprecated API (document.execCommand) as a fallback for browsers that didn't implement the standard API.

We only use the following methods from the standard Clipboard API:

  • writeText, to put content into the users' clipboard (widely available, since Safari 13.4 (~March 2020))
  • readText, to read content from the users' clipboard (widely available, since Firefox 125 (~April 2024))

It seems that soon we'll be able to remove the execCommand fallback, and all the scaffolding to make it work.

See ExecCommand* strategy classes here:

(PS: We should also remove the execCommand definition from the engine's dom.dart!)


Closes: #48581

Activity

  1. added
    engineflutter/engine related. See also e: labels.
    c: tech-debtTechnical debt, code quality, testing, etc.
    team-webOwned by Web platform team
    on Oct 24, 2024
  2. added
    platform-webWeb applications specifically
    P2Important issues not at the top of the work list
    triaged-webTriaged by Web platform team
    on Nov 7, 2024
  3. github-actions commented on Jul 25, 2025

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  4. locked as resolved and limited conversation to collaborators on Jul 25, 2025
  5. added a commit that references this issue on Sep 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work listc: tech-debtTechnical debt, code quality, testing, etc.engineflutter/engine related. See also e: labels.platform-webWeb applications specificallyteam-webOwned by Web platform teamtriaged-webTriaged by Web platform team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions