A handy browser plugin to search docs and packages in the address bar instantly
Tags: tools, go, search, doc
Published: 2020-07-16 09:02:23

Hi all. I'm so honored to introduce my product: **Go Search Extension,** a handy browser plugin to help every Go developer search docs and package in the address bar instantly. 

How does it work? Easy! Just input keyword **go** + **Space** in the address bar to activate the extension, then input any keyword you wanna search, the extension will respond to the related result in an instant! It's hugely fast just like a **millisecond-level** search! Why it so fast? Because we build the offline index file for whole standard docs and packages!

I'm also the creator of **Rust Search Extension**, which gets a lot of traction from the rust community. More programming versions (such as C/C++, Javascript) are coming. See [https://github.com/huhu](https://github.com/huhu) if you want to know more.

Let's explain it in more detail:

### Search std docs

The whole standard library is searchable. No matter a `package`, `func`, or `interface`, the result you desired is just a keystroke away. Select one and enter, you'll be redirected to the proper [pkg.go.dev](http://pkg.go.dev) page effortlessly.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/vfh4bq4mm7d307ct12og.png)

### Search top 20K packages

Just searching the std library is not enough. So we crawled top starred Go packages from Github and built the index file for TOP 20K, everyone can search those great packages easily and instantly. 

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/uml4x31980d00w35vpnf.png)

Hope you like it, we bring several prefix sign to help you search the corresponding kind of content exclusively. For example, the **!** is package searching prefix, the **!!** is repository mode prefix, the **$** is the awesome golang list searching prefix (See the following part). If no prefix sign is specified, the default search is the standard library. :)

### Quick jump to git repository

While we searching the top package, we also hope we can jump to the package repository directly. Yeah, this is possible! Just prefix **!!** before the keyword, you'll open the repository page instead of the default [pkg.go.dev](http://pkg.go.dev) page. However, we only support Github, Gitlab, Bitbucket, Gitea, etc.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/waqutdzrqpkzw6n9cdv6.png)

### Awesome golang list search

[Awesome Golang](https://github.com/avelino/awesome-go) is an awesome resource itself for searching. Hence, we indexed the whole list! 

Prefix **$** before the keyword, you'll get the desired result from the awesome list.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/ut2uza9b3dxid9iqs566.png)

### Builtin commands

The command system brings a handy set of useful and convenient commands to you. Each command starts with a : (colon), followed by the name, and function differently in individual. Those commands including but not limited to:

- `:help` - Show the help messages.
- `:book` - Show all Golang e-books.
- `:conf` - Show Golang conferences.
- `:meetup` - Show Golang meetups.
- `:social` - Show Golang social media.
- `:history` - Show your local search history

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/n7jlboaktkcn0lirkwyp.png)

## **Page down/up easily**

You can press `space` after the keyword, then increase or decrease the number of **-** (hyphen) to page down or page up.

## Installation

- [Chrome Web Store](https://chrome.google.com/webstore/detail/golang-search/epanejkfcekejmmfbcpbcbigfpefbnlb)
- [Firefox](https://addons.mozilla.org/en-US/firefox/addon/go-search-extension/)
- [Microsoft Edge](https://microsoftedge.microsoft.com/addons/detail/ebibclchdmagkhopidkjckjkbhghfehh)

### Some links

Github: [https://github.com/huhu/go-search-extension](https://github.com/huhu/go-search-extension)

Organization: [https://github.com/huhu](https://github.com/huhu)

Welcome to give it a try. If you find a bug or something missed, please don't hesitate to let me know. Of course, any issue or PR is welcome too! Thanks! :)