hexo with algolia search

Enable algolia search with the following steps:

  1. register on www.aloglia.com
  2. create index and api key
  3. update hexo config

    1
    2
    3
    4
    5
    algolia:
    applicationID: '<your application id>'
    apiKey: '<you search api key>'
    indexName: '<index name>'
    chunkSize: 5000
  4. update next theme config

    1
    2
    3
    4
    5
    6
    7
    8
    9
    # Algolia Search
    algolia_search:
    enable: true
    hits:
    per_page: 10
    labels:
    input_placeholder: input keywords
    hits_empty: "not found ${query} related contents"
    hits_stats: "${hits} records,total used ${time} ms"
  5. upload data to algolia

    1
    hexo algolia --flush