{"id":118,"date":"2019-09-25T07:29:22","date_gmt":"2019-09-25T07:29:22","guid":{"rendered":"https:\/\/docs.theironnetwork.org\/reactify\/?page_id=118"},"modified":"2019-11-13T07:24:01","modified_gmt":"2019-11-13T07:24:01","slug":"instant-search-with-algolia","status":"publish","type":"page","link":"https:\/\/docs.theironnetwork.org\/reactify\/instant-search-with-algolia\/","title":{"rendered":"Instant Search With Algolia"},"content":{"rendered":"\n<p>We have used shop page example to integrate instant search. There is a lot of other pre-made demo examples on the<a rel=\"noreferrer noopener\" href=\"https:\/\/community.algolia.com\/react-instantsearch\/examples\/Demos.html\" target=\"_blank\"> official doc<\/a>. In Reactify you can see the demo on this url <a href=\"https:\/\/reactify.theironnetwork.org\/app\/ecommerce\/shop\" target=\"_blank\" rel=\"noreferrer noopener\" aria-label=\"https:\/\/reactify.theironnetwork.org\/app\/ecommerce\/shop (opens in a new tab)\">https:\/\/reactify.theironnetwork.org\/app\/ecommerce\/shop<\/a>.<\/p>\n\n\n\n<p><strong>Getting Started:<\/strong><\/p>\n\n\n\n<p><strong>Step 1:<\/strong> Create an account on <a href=\"https:\/\/www.algolia.com\/users\/sign_up\" target=\"_blank\" rel=\"noreferrer noopener\">Algolia<\/a>. <\/p>\n\n\n\n<p><strong>Step 2:<\/strong> After Signup you will get the 14 days trial and you will update the plan according to your requirements. <strong>Reference Link : <\/strong><a href=\"https:\/\/www.algolia.com\/pricing\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/www.algolia.com\/pricing<\/a><\/p>\n\n\n\n<p><strong>Step 3:<\/strong> Create an Index on Algolia Dashboard by clicking on the indices tab from the left menu and then clicking on create index button. Please check the screenshot below for reference:<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><img loading=\"lazy\" width=\"1024\" height=\"380\" src=\"https:\/\/docs.theironnetwork.org\/reactify\/wp-content\/uploads\/sites\/4\/2019\/09\/algolia1-1024x380.png\" alt=\"\" class=\"wp-image-119\" srcset=\"https:\/\/docs.theironnetwork.org\/reactify\/wp-content\/uploads\/sites\/4\/2019\/09\/algolia1-1024x380.png 1024w, https:\/\/docs.theironnetwork.org\/reactify\/wp-content\/uploads\/sites\/4\/2019\/09\/algolia1-300x111.png 300w, https:\/\/docs.theironnetwork.org\/reactify\/wp-content\/uploads\/sites\/4\/2019\/09\/algolia1-768x285.png 768w, https:\/\/docs.theironnetwork.org\/reactify\/wp-content\/uploads\/sites\/4\/2019\/09\/algolia1.png 1281w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure><\/div>\n\n\n\n<p><strong>Step 4:<\/strong> Add your products fields with values under the newly created Index.\n\n<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><img loading=\"lazy\" width=\"1024\" height=\"432\" src=\"https:\/\/docs.theironnetwork.org\/reactify\/wp-content\/uploads\/sites\/4\/2019\/09\/algolia2-1024x432.png\" alt=\"\" class=\"wp-image-120\" srcset=\"https:\/\/docs.theironnetwork.org\/reactify\/wp-content\/uploads\/sites\/4\/2019\/09\/algolia2-1024x432.png 1024w, https:\/\/docs.theironnetwork.org\/reactify\/wp-content\/uploads\/sites\/4\/2019\/09\/algolia2-300x126.png 300w, https:\/\/docs.theironnetwork.org\/reactify\/wp-content\/uploads\/sites\/4\/2019\/09\/algolia2-768x324.png 768w, https:\/\/docs.theironnetwork.org\/reactify\/wp-content\/uploads\/sites\/4\/2019\/09\/algolia2.png 1302w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure><\/div>\n\n\n\n<p><strong>Step 5: <\/strong>You need to change your app name in the manage applications page. Just open the given url, edit the app and give your app a name. This app name is used in the template. <\/p>\n\n\n\n<div class=\"custom-sec-wrap mb-4\">\n\t<a href=\"https:\/\/www.algolia.com\/manage\/applications\" class=\"link-wrap\">\n\t\t<div class=\"content-wrap\">\n\t\t\t<h6>Sign in<\/h6>\n\t\t\t<p style=\"font-weight:400;\">Algolia&#8217;s Search API makes it easy to deliver a great search experience in your apps &amp; websites. Algolia Search provides hosted full-text, numerical, faceted and geolocalized search.<\/p>\n\t\t\t<small>www.algolia.com<\/small>\n\t\t<\/div>\n\t\t<div style=\"background-image:url('https:\/\/www.algolia.com\/assets\/social-media-covers\/header-big-faca54f9889303ced158616eb85f8010.jpg');\" class=\"ironthm-img-item\"><\/div>\n\t<\/a>\n<\/div>\n\n\n\n<p><strong>Step 6:<\/strong> Now open the API keys tab from the left menu and copy the <code>Search-Only API Key<\/code> , now open the <code>src-&gt;routes-&gt;ecommerce-&gt;shop-&gt;index.js<\/code>file from the template and paste the credentials in the <code>apiKey<\/code>, <code>indexName<\/code> with the index you have created &amp; <code>appId<\/code> with the app name you have given to your app in step 5.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">&lt;InstantSearch<br>   appId=\"&lt;app name&gt;\" \/\/ created in step 5<br>   apiKey=\"&lt;api key&gt;\" \/\/ copied in step 6<br>   indexName=\"&lt;index name&gt;\" \/\/ created in step 3<br>&gt;<br>&lt;\/InstantSearch&gt; <\/pre>\n\n\n\n<p>To get more information about algolia instant search check the official <a href=\"https:\/\/community.algolia.com\/react-instantsearch\/\" target=\"_blank\" rel=\"noreferrer noopener\">document<\/a>.<\/p>\n<div class=\"pld-like-dislike-wrap pld-template-1\">\n    <div class=\"pld-like-wrap  pld-common-wrap\">\n    <a href=\"javascript:void(0);\" class=\"pld-like-trigger pld-like-dislike-trigger \" title=\"\" data-post-id=\"118\" data-trigger-type=\"like\" data-restriction=\"cookie\" data-ip-check=\"0\" data-user-check=\"1\">\n                        <i class=\"fas fa-thumbs-up\"><\/i>\n                    <\/a>\n    <span class=\"pld-like-count-wrap pld-count-wrap\">1    <\/span>\n<\/div><div class=\"pld-dislike-wrap  pld-common-wrap\">\n    <a href=\"javascript:void(0);\" class=\"pld-dislike-trigger pld-like-dislike-trigger \" title=\"\" data-post-id=\"118\" data-trigger-type=\"dislike\" data-ip-check=\"0\" data-restriction=\"cookie\" data-user-check=\"1\">\n                        <i class=\"fas fa-thumbs-down\"><\/i>\n                    <\/a>\n    <span class=\"pld-dislike-count-wrap pld-count-wrap\"><\/span>\n<\/div><\/div>\n\n","protected":false},"excerpt":{"rendered":"<p>We have used shop page example to integrate instant search. There is a lot of other pre-made demo examples on the official doc. In Reactify you can see the demo on this url https:\/\/reactify.theironnetwork.org\/app\/ecommerce\/shop. Getting Started: Step 1: Create an account on Algolia. Step 2: After Signup you will get the 14 days trial and [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":37,"comment_status":"closed","ping_status":"closed","template":"","meta":[],"_links":{"self":[{"href":"https:\/\/docs.theironnetwork.org\/reactify\/wp-json\/wp\/v2\/pages\/118"}],"collection":[{"href":"https:\/\/docs.theironnetwork.org\/reactify\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/docs.theironnetwork.org\/reactify\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/docs.theironnetwork.org\/reactify\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.theironnetwork.org\/reactify\/wp-json\/wp\/v2\/comments?post=118"}],"version-history":[{"count":13,"href":"https:\/\/docs.theironnetwork.org\/reactify\/wp-json\/wp\/v2\/pages\/118\/revisions"}],"predecessor-version":[{"id":714,"href":"https:\/\/docs.theironnetwork.org\/reactify\/wp-json\/wp\/v2\/pages\/118\/revisions\/714"}],"wp:attachment":[{"href":"https:\/\/docs.theironnetwork.org\/reactify\/wp-json\/wp\/v2\/media?parent=118"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}