HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
tridactyl
keyboard-api
JavaScript2017–2023
tridactyl / keyboard-api

keyboard-api

webextension experiment offering a lower level keypress-related API

3Distinct people
9Mentions
0Explicit recommenders
56GitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

webextension experiment offering a lower level keypress-related API

GitHub

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 1:49:46 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year9 dated mentions

Observed mentions: 2017-11-13 19:39:17 UTC to 2023-02-28 12:05:18 UTC.

0122017-01-01 00:00:00 UTC to 2018-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments20172018-01-01 00:00:00 UTC to 2019-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2019-01-01 00:00:00 UTC to 2020-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments20202021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2023

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20172017-01-01 00:00:00 UTC2018-01-01 00:00:00 UTC202
20182018-01-01 00:00:00 UTC2019-01-01 00:00:00 UTC202
20192019-01-01 00:00:00 UTC2020-01-01 00:00:00 UTC202
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC101
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC000
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC000
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC202

What Hacker News says

9 sources
Mozilla said they were happy to do that five years ago if we wrote the API. We started work on it here [1] but lost interest because there have always been more urgent things to do (and for me, the ctrl+comma escape hatch that gets you back to Tridactyl from anywhere in the browser is good enough). I think honestly most of the work in getting such an API merged would be political since most of the people who approved it are no longer at Mozilla. If anyone wants to pick it up I would be delighted to help. [1]: https://github.com/tridactyl/keyboard-api
In Vimium – A browser extension that provides Vim-style keyboard controls
About five years ago we had agreement in principle with Mozilla to extend the web extension API to accept keypresses from anywhere, provided that someone did the work to write that API. We started it [1] but lost interest because we think Tridactyl works mostly fine without it (press ctrl+, anywhere to get back to Tridactyl) and I have always found more urgent things to improve. I'd be happy to help anyone who wanted to pick it up, but a lot of the political work of persuading Mozilla that such an API would be useful would need to be restarted since most of the people we persuaded in the past have now left Mozilla. [1]: https://github.com/tridactyl/keyboard-api/
In Why did Mozilla remove XUL add-ons? (2020)
I think the main limitation is not being able to accept key presses from browser chrome. Mozilla in principle was prepared to accept a patch that added a new API that did that [1] but people have repeatedly lost interest in developing it - the reward for getting it working being a months-long negotiation with Mozilla to get it merged probably doesn't make it appealing to many. The API would also fix some but not all instances of not being able to use Tridactyl until the page has loaded. Recently, we have added an escape hatch where if you press ctrl-, focus returns to the page even from browser chrome. This works even on special pages like "we could not load this page" where it returns you to a page where Tridactyl can run. I've trained myself to use it instead of escape and it feels quite natural. On every platform except Windows ctrl-6
Read the rest
now takes you to the previous tab everywhere, even on pages to which we don't normally have access. Users can add their own octopus-style binds which are accessible everywhere but the criteria for what works are unfortunately quite opaque. I personally think the biggest problems for Tridactyl are in the future. Manifest v3 proposes heavily restricting the use of `eval` which our users use a lot for writing their own little scripts. I don't think it would be insurmountable, but Tridactyl already has its own little DSL, so we would probably run afoul of the spirit of the new rules and risk getting delisted or banned. We might have to take most of the coolest features of Tridactyl out (and maybe have a contrib/ part of the source where anyone can have their own scripts merged without too much review). The other problem is that new web extension APIs tend be gated behind a very narrow definition of "user intent" - essentially, the user clicks on your extension button or presses an octopus-style keybind (like ctrl-,) - that excludes about 99% of the intent of Tridactyl users. A recent example of this is the new "optional permissions" where an extension can ask for permissions as it needs them; Firefox requires you can convince it that you have user intent or it will not allow you to ask for more permissions. (Incidentally, the keyboard API I mentioned above would allow us to prove user intent to Firefox in some limited circumstances). So in summary: yeah, there are limitations. Lots of them could be fixed by working with Mozilla but no one has yet been motivated enough. In practice it's not as bad as it sounds. [1]: https://github.com/tridactyl/keyboard-api
In Tridactyl: A Vim-like interface for Firefox
FWIW, there's at least one (minor) change that was made to Firefox to help out Tridactyl - https://github.com/tridactyl/tridactyl/issues/792. Mozilla also were happy in principle to allow us to intercept key presses on all parts of the browser last time we spoke to them a couple of years ago; we just need someone to write that extension to the WebExtension API - https://github.com/tridactyl/keyboard-api. Rewriting Tridactyl in XUL is not something I would wish on anyone.
In All Tridactyl installations might get removed by Firefox on Aug 21
Yeah, I see where you're coming from. cmcaine started on an extension to the WebExtension API [1] that would fix that, but progress has stalled. It got preliminary approval and was split up into loads of bugs on Bugzilla at which point we all got a bit lost. If you feel very strongly about it, perhaps you could pick up the baton? Part of the reason I haven't done so is because I disagree with you - Tridactyl is pretty usable to me, and there's loads of things I want to fix in that that are a higher priority to me. [1] https://github.com/cmcaine/keyboard-api
In Firefox is back. It's time to give it a try
Less "dire warnings on forums" and more "slow development pace for required pieces to make my workflow even possible again". Here's an issue opened June 9 that hasn't been addressed by the Mozilla team and hasn't had any updates in a month: https://github.com/cmcaine/keyboard-api/issues/1 Here's the request for a better keyboard API (referenced in the above) that's been open for over 2 years with no end in sight: https://bugzilla.mozilla.org/show_bug.cgi?id=1215061 I'm sure the new FF is going to make some users happy, but as you said, having your workflow broken is quite painful, and the Mozilla team has known about this for years but still not made the upgrade path bearable.
In How Firefox Got Fast Again

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.