曾经有一个非常不错的Chrome扩展程序,用于直接从“多功能框”(Google Chrome浏览器顶部的搜索栏)搜索Oracle的Javadoc(Java文档)。
但是,自Java 7(2014年前)以来,该扩展一直未得到维护,因此非常过时。
中号y new extension can be used to search the documentation of any JDK (Java Development Kit) version 9 through 13, inclusive.
开发Omnibox扩展程序需要一些工作(特别是如果您对像我这样的JavaScript回调不太熟悉的话),但是最终结果却很酷:
I've never done anything like this before, so my solution is definitely suboptimal (for instance, I simulate a search entry in an input
field with key events, rather than interfacing with the search code itself). If anyone who knows a bit of JavaScript would be willing to help out, feel free to submit a pull request!
If you're interested in creating your own Omnibox extensions, there are some examples online. If you know a bit of JavaScript, it's really easy -- just a single function that gets called when the user uses a keyword in the Omnibox. Not very spoopy, but that's my Hacktoberfest contribution to the world!
If you enjoyed this post, please consider supporting my work by buying me a coffee!