thom4parisot / hexo-algolia

Index your hexo website content to Algolia Search.
https://npmjs.com/hexo-algolia
MIT License
88 stars 15 forks source link

Do not index page.content #24

Closed thom4parisot closed 7 years ago

thom4parisot commented 7 years ago

For two reasons:

  1. algolia has a default size limit of 10kB for an indexed object (and it goes quicker with Chinese and Japanese)
  2. title and excerpt should be where the important words are (tags are good descriptors too)

Characters U+0800 through U+FFFF use three bytes in UTF-8, but only two in UTF-16. As a result, text in (for example) Chinese, Japanese or Devanagari will take more space in UTF-8 if there are more of these characters than there are ASCII characters. – via https://en.wikipedia.org/wiki/UTF-8

fixes #15