WebExtension Experiment For Firefox Tags
Since the WebExtensions API does not currently support bookmarks tags, I created this WebExtension Experiment API to expose some of the internal Firefox API for tags, thus enabling users/developers to access/read/retrieve bookmark tags in their own extensions.
NOTE: It is very likely that this API will not work in the near future, as there are plans to merge the tagging API with the bookmarking API.
How to install this API and WebExtension
- Run a non-release build (Nightly or unbranded Beta/Release) version 59 (or newer) build.
- Navigate to
about:configand set the pref
- Navigate to
about:debugging, choose "Load Temporary Add-on" and select
manifest.jsonin this project. You should see a new entry in the list of extensions titled "Firefox Bookmark Webhooks".
You should see a new toolbar icon that resembles a tag.
getURIsForTag(tag) - Finding all URLs with a given tag
const uris = browser.experiments.tags.getURIsForTag("tag 1"); // Returns an array of URIs
getTagsForURI(URI) - Getting all tags associated with a URL
const tags = browser.experiments.tags.getTagsForURI("http://example.com/"); // Returns an array of tags stored for that URI
- Firefox issue tracker #1225916
- StackOverflow Question About Getting Bookmark Tags
- WebExtensions API currently not supporting bookmarks tags
- WebExtensions API Development
- Using The Places Tagging Service
- XPConnectWrappers More Information
This software is supplied "AS IS" without any warranties and support.