Skip to content

Instantly share code, notes, and snippets.

@oliviagallucci
Last active July 9, 2023 01:27
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
Definitions Bookmarklet - Select a word on a webpage, click the bookmarklet, and a new tab with Google's definition of the word will appear
javascript:d=""+(window.getSelection?window.getSelection():document.getSelection?document.getSelection():document.selection.createRange().text);d=d.replace(/\r\n|\r|\n/g,"%20,");if(!d)d=prompt("Enter%20Word:",%20"");if(d!=null)location="http://www.google.com/search?q=define:"+escape(d).replace(/%20/g,"+");void(0);
@oliviagallucci
Copy link
Author

oliviagallucci commented Jul 9, 2023

If you want to use a different dictionary, replace http://www.google.com/search?q=define: and the formatting past it with the code needed to use your dictionary. Alternatively, you can search the internet to see if someone created one with your desired dictionary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment