Use Elasticsearch to power your product search
This plugin allows your product search to be powered by Elasticsearch - a powerful Open Source search engine. This is a drop-in replacement for the DefaultSearchPlugin which exposes many powerful configuration options enabling your storefront to support a wide range of use-cases such as indexing of custom properties, fine control over search index configuration, and to leverage advanced Elasticsearch features like spacial search.
Installation
Requires Elasticsearch v7.0 - 7.10. Elasticsearch version 7.10.2 will throw error due to incompatibility with elasticsearch-js client. Check here for more info.
npm install @elastic/elasticsearch @vendure/elasticsearch-plugin
Make sure to remove the DefaultSearchPlugin if it is still in the VendureConfig plugins array.
Then add the ElasticsearchPlugin, calling the .init() method with ElasticsearchOptions:
import { ElasticsearchPlugin } from '@vendure/elasticsearch-plugin';
const config: VendureConfig = {
// Add an instance of the plugin to the plugins array
plugins: [
ElasticsearchPlugin.init({
host: 'http://localhost',
port: 9200,
}),
],
};
Complete documentation
See the ElasticsearchPlugin docs for complete documentation.
Create your first commerce experience with Vendure in less than 2 minutes
Vendure is a registered trademark. Our trademark policy ensures that our brand and products are protected. Feel free to reach out if you have any questions about our trademarks.
Documentation
Newsletter
Get the latest product news and announcements delivered directly to your inbox.