Yet Another Hints Extension
I wasn't fully satisfied with the hit-a-hint extensions available for Chrome and Firefox, so I made my own. These are the existing extensions that worked as inspiration for this one:
- Press the hint key to activate the hints. The default hint key is
- Type the code of the hint you want to activate.
- Once hint is highlighted, press enter key to simulate a mouse click on the link. You can the key press with modifiers like Ctrl and Shift to simulate a click with modifiers.
- After activating a hint, the typing buffer is cleared, so you can continue by typing another code.
You can deactivate the hints by pressing the escape key. Pressing the hint key after typing some characters clears the typing buffer, and pressing it again deactivates the hints.
In Chrome, you can customize the hint key and hint characters in the extension's options page.
Install from Chrome Web Store.
There are two ways to install this extension: from this extension's Chrome Web Store page or from repository sources.
Installing for Chrome from repository sources
- Clone YAHE Git repository:
git clone git://github.com/Lepovirta/yahe.git
- Fire up you Chrome/Chromium browser, and go to the extensions section of the settings page.
- Enable the developer mode by checking the developer mode checkbox.
- Click the Load unpacked extension... button.
- Select the directory where you cloned the repository to.
If you want to update the extension, pull the latest changes from the
repository to your cloned directory (
git pull), and either restart your
browser or hit the extension's reload button in extensions page.
Extending the script
If you want to edit the source code, I recommend installing the following tools:
All the code for YAHE is located in the
src/ directory, and
yahe.user.js are just the build outputs.
If you have Browserify installed, you can execute
file using a Bourne shell (
sh) compatible shell to build the final script.
The entry point for YAHE is in the
main.js file, which does all the
initialization. It imports most of the code from other source files, and it's a
good place to start reading the code.
If you want to change the settings for the script, change the values in
defaults.js source file. Remember to rebuild the final script.
(2-clause BSD license)
Copyright (c) 2012-2014, Jaakko Pallari All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
- Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.