Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposal: Remove multiple bookmarks in bookmarks.remove() #640

Open
erosman opened this issue Jun 17, 2024 · 1 comment
Open

Proposal: Remove multiple bookmarks in bookmarks.remove() #640

erosman opened this issue Jun 17, 2024 · 1 comment
Labels
needs-triage: chrome Chrome needs to assess this issue for the first time supportive: firefox Supportive from Firefox supportive: safari Supportive from Safari

Comments

@erosman
Copy link

erosman commented Jun 17, 2024

Background

The bookmarks.remove() API allows the removal of a single bookmark.

Extensions dealing with bookmarks would benefit from having the option to remove multiple bookmarks with a single requests, instead of removing them one by one.

Proposal

Update the API to accept string, or array of strings, similar to StorageArea.remove().

let removingBookmark = browser.bookmarks.remove(
  ids              // string, or array of strings
)
@github-actions github-actions bot added needs-triage: chrome Chrome needs to assess this issue for the first time needs-triage: firefox Firefox needs to assess this issue for the first time needs-triage: safari Safari needs to assess this issue for the first time labels Jun 17, 2024
@carlosjeurissen
Copy link
Contributor

To add some context. Seems one of the motivations for this proposal is performance. Removing a big amount of bookmarks can take some time.

In this thread, (erosman/support#595) @bilgincoskun mentions:

The main caveats with the current API are:

  • It is true that with many bookmarks, it takes long time to remove all links, although with async calls, the browser continues to work fine. I didn't try with 5000+ tabs but from what I see with about 500 bookmarks the main the bottleneck is bookmark numbers, whether the bookmarks are in the same folder, if they have only one copy etc. and not tab number.
  • Same cannot be said for bookmark operations. Adding new bookmarks lags for several seconds.
  • Although not due to the extension but the API itself, another caveat is about tags. When removed and added back, same tags are still present until removed from the dialog.

@xeenon xeenon added supportive: safari Supportive from Safari and removed needs-triage: safari Safari needs to assess this issue for the first time labels Jun 20, 2024
@zombie zombie added supportive: firefox Supportive from Firefox and removed needs-triage: firefox Firefox needs to assess this issue for the first time labels Jun 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-triage: chrome Chrome needs to assess this issue for the first time supportive: firefox Supportive from Firefox supportive: safari Supportive from Safari
Projects
None yet
Development

No branches or pull requests

4 participants