1
0
Fork 0

chore(doc): Update README for v2 (#122)

This commit is contained in:
Rémy-Christophe Schermesser 2016-07-07 14:14:33 +02:00 committed by GitHub
parent 66e68a9aec
commit c1b0926b32
5 changed files with 13 additions and 9 deletions

View file

@ -170,7 +170,7 @@ npm run release:beta
This task will release a beta version of what is currently in develop branch.
It will not update the `latest` tag of the npm release nor update jsDelivr /1/.
It will not update the `latest` tag of the npm release nor update jsDelivr /2/.
# Hotfixes

View file

@ -58,14 +58,16 @@ you need to integrate your new search into your website.
2. We'll configure your search experience,
3. You'll need to add a bit of JavaScript and CSS code to your website.
If you prefer to DIY, you can run the [scraper][28] in your own infra.
## Setup
Once we've crawled your documentation website we'll send you the credentials you
need to add the following code snippet to your website:
```html
<link rel="stylesheet" href="//cdn.jsdelivr.net/docsearch.js/1/docsearch.min.css" />
<script type="text/javascript" src="//cdn.jsdelivr.net/docsearch.js/1/docsearch.min.js"></script>
<link rel="stylesheet" href="//cdn.jsdelivr.net/docsearch.js/2/docsearch.min.css" />
<script type="text/javascript" src="//cdn.jsdelivr.net/docsearch.js/2/docsearch.min.js"></script>
<script type="text/javascript">
docsearch({
apiKey: '<API_KEY>',
@ -77,7 +79,7 @@ docsearch({
## Customization
The default colorscheme is blue and gray:
The default colorscheme is white and gray:
![Default colorscheme][17]
@ -141,6 +143,7 @@ You can regenerate the whole final `css` file from those `scss` files by running
All you have to do now is change the `link` tag that was loading the default
styling from our CDN, to one that is loading your newly compiled file.
## Custom options
DocSearch is a wrapper around the [autocomplete.js][20] library that gets its
@ -260,7 +263,7 @@ bundle config build.eventmachine --with-cppflags=-I$(brew --prefix openssl)/incl
[4]: https://img.shields.io/coveralls/algolia/docsearch/master.svg?style=flat-square
[5]: http://img.shields.io/badge/license-MIT-green.svg?style=flat-square
[6]: https://img.shields.io/npm/dm/docsearch.js.svg?style=flat-square
[7]: ./docs/img/showcase/example-eslint.gif
[7]: ./docs/img/showcase/example-apiary.gif
[8]: #introduction
[9]: #setup
[10]: #customization
@ -270,7 +273,7 @@ bundle config build.eventmachine --with-cppflags=-I$(brew --prefix openssl)/incl
[14]: #documentation-website
[15]: #macos
[16]: https://community.algolia.com/docsearch/
[17]: https://community.algolia.com/docsearch/img/default-colorscheme.png
[17]: ./docs/img/default-colorscheme.png
[18]: https://github.com/algolia/docsearch/blob/master/src/styles/_variables.scss
[19]: https://github.com/algolia/docsearch/blob/master/src/styles/main.scss
[20]: https://github.com/algolia/autocomplete.js
@ -281,5 +284,6 @@ bundle config build.eventmachine --with-cppflags=-I$(brew --prefix openssl)/incl
[25]: https://jekyllrb.com/
[26]: https://www.ruby-lang.org/en/
[27]: http://bundler.io/
[28]: https://github.com/algolia/docsearch-scraper
<!-- END links -->

View file

@ -62,7 +62,7 @@
</script>
{% endif %}
<script type="text/javascript" src="//cdn.jsdelivr.net/docsearch.js/1/docsearch.min.js"></script>
<script type="text/javascript" src="//cdn.jsdelivr.net/docsearch.js/2/docsearch.min.js"></script>
<script type="text/javascript">
var myDocSearch = docsearch({
apiKey: '25626fae796133dc1e734c6bcaaeac3c',

View file

@ -26,8 +26,8 @@ Once we've crawled your documentation website we'll send you the credentials you
need to add the following code snippet to your website:
```html
<link rel="stylesheet" href="//cdn.jsdelivr.net/docsearch.js/1/docsearch.min.css" />
<script type="text/javascript" src="//cdn.jsdelivr.net/docsearch.js/1/docsearch.min.js"></script>
<link rel="stylesheet" href="//cdn.jsdelivr.net/docsearch.js/2/docsearch.min.css" />
<script type="text/javascript" src="//cdn.jsdelivr.net/docsearch.js/2/docsearch.min.js"></script>
<script type="text/javascript">
docsearch({
apiKey: '<API_KEY>',

Binary file not shown.

Before

Width:  |  Height:  |  Size: 43 KiB

After

Width:  |  Height:  |  Size: 46 KiB