Searchkit is an open source library which helps you build a great search experience with Elasticsearch.
const searchkitConfig = {host: 'http://demo.searchkit.co/api/',index: 'movies',hits: {fields: [ 'title', 'plot', 'poster' ]},query: new MultiMatchQuery({fields: [ 'plot','title^4']}),facets: [new RefinementSelectFacet({field: 'type.raw',id: 'type',label: 'Type'}),new RefinementSelectFacet({field: 'writers.raw',id: 'writers',label: 'Writers',multipleSelect: true}),new RangeFacet({field: 'metaScore',id: 'metascore',label: 'Metascore',range: {min: 0,max: 100,interval: 5}}),new DateRangeFacet({field: 'released',id: 'released',label: 'Released'})]}
{results(query: "heat",filters: [{id: "type",value: "movie"}]) {facets {idlabeltypedisplayentries {idlabelcount}}hits {items {idfields {titlewritersactors}}}}}
Searchkit GraphQL resolvers saves building a search focused API with common use cases such as facet filtering, pagination and querying.
yarn add @searchkit/apollo-resolvers
With Apollo, Elasticsearch and Searchkit's resolvers, its extremely quick to build a capable dev friendly search API.
Searchkit provides filtering on text, numbers and dates.
All the heavy lifting is done by the API, making it easy to integrate your React website or Swift iOS App.
Easily extend and add your own facets. Write your own resolvers to provide information that comes from other sources, not just from elasticsearch.
For those who want a search UI quickly, Searchkit provides UI components out the box which work with Searchkit's API to bring a great search experience to your app. Searchkit components leverages Elastic's EUI react components.
yarn add @searchkit/client @searchkit/elastic-ui @elastic/eui