Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a how to add search to your website section #5272

Merged
merged 17 commits into from
May 16, 2018
Merged
18 changes: 18 additions & 0 deletions docs/docs/adding-search.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
title: "Adding search to your Gatsby website"
---

There are few ways to approach adding search to your Gatsby-powered site:

1. You can use libraries such as [elesticlunr][1] for offline search but doing so will require you to index at build time. Fortunately, this is achievable using the [gatsby-plugin-elasticlunr-search][2] plugin
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

...plugin. (needs a period to be consistent with the rest of this doc)


2. If you're building a website for your documentation, you can use the [Algolia docs][3] feature--it scrapes the dom and builds the search index automatically. After that, you'll need to implement your own [search ui][4].
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Capitalize DOM and UI


3. Use Algolia to collect the search index at build time and upload it to using [gatsby-plugin-algolia][5].
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

delete "to" in "to using"



[1]: https://www.npmjs.com/package/elasticlunr
[2]: https://github.com/andrew-codes/gatsby-plugin-elasticlunr-search
[3]: https://www.algolia.com/doc/
[4]: https://www.algolia.com/doc/paths/build-search-ui/
[5]: https://github.com/algolia/gatsby-plugin-algolia
2 changes: 2 additions & 0 deletions www/src/pages/docs/doc-links.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@
link: /docs/creating-dynamically-rendered-navigation/
- title: Dropping Images into Static Folders*
link: /docs/dropping-images-into-static-folders/
- title: Adding search to your Gatsby website
link: /docs/adding-search/
- title: Reference
items:
- title: Node Interface
Expand Down