1- import   *   as   page  from   "./page" ; 
1+ const   page  =   require ( "./page" ) ; 
22
33// Algolia index settings. 
44// 
55// Changes to this file should be made with extreme care. 
6+ module . exports  =  { 
67
78    // Attributes for faceting are the properties to use for top-level filtering of results -- for 
89    // example, whether a given record is returned for a "Docs" query, "Registry" query, and so on. 
910    // https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/ 
10-     export   function   getAttributesForFaceting ( )  { 
11+     getAttributesForFaceting ( )  { 
1112        return  [ 
1213            "searchable(section)" , 
1314        ] ; 
14-     } 
15+     } , 
1516
1617    // Synonyms allow us to surface content that may not directly match users' queries. 
1718    // https://www.algolia.com/doc/api-reference/api-methods/save-synonyms/#save-synonyms 
18-     export   function   getSynonyms ( )  { 
19+     getSynonyms ( )  { 
1920        return  [ 
2021            [ ".NET" ,  "dotnet" ] , 
2122            [ "aws" ,  "aws classic" ] , 
@@ -47,7 +48,7 @@ import * as page from "./page";
4748                synonyms, 
4849            } ; 
4950        } ) ; 
50-     } 
51+     } , 
5152
5253    // Searchable attributes control the fields that Algolia uses for query matching, as well as how 
5354    // relevant those fields are in relation to one another. 
@@ -57,7 +58,7 @@ import * as page from "./page";
5758    // the change on an index that isn't production. 
5859    // 
5960    // https://www.algolia.com/doc/guides/sending-and-managing-data/prepare-your-data/how-to/setting-searchable-attributes/#set-searchable-attributes-with-the-api 
60-     export   function   getSearchableAttributes ( )  { 
61+     getSearchableAttributes ( )  { 
6162        return  [ 
6263            "title,h1" ,             // Title and H1 are considered of equal relevance, so they're listed on the same level. 
6364            "keywords" ,             // Keywords are treated as ordered. Those higher up in the list are considered more relevant. 
@@ -68,25 +69,25 @@ import * as page from "./page";
6869            "section" ,              // Section is the primary "facet" of a record -- Docs, Registry, Blog, Examples, etc. 
6970            "unordered(authors)" ,   // Blog-post authors are occasionally useful for searching, but their order is considered irrelevant. 
7071        ] ; 
71-     } 
72+     } , 
7273
7374    // Attributes to highlight contains the list of searchable attributes that might be used to highlight query matches in the UI. 
7475    // https://www.algolia.com/doc/api-reference/api-parameters/attributesToHighlight/ 
75-     export   function   getAttributesToHighlight ( )  { 
76+     getAttributesToHighlight ( )  { 
7677        return  [ 
7778            "title" , 
7879            "h1" , 
7980            "description" , 
8081        ] ; 
81-     } 
82+     } , 
8283
8384    // Custom rankings are the attributes that Algolia uses for determining relative ranking -- 
8485    // specifically for breaking ties between records that rank similarly for text matching. Similar 
8586    // to the above, order here is significant as well, so any changes here should be made with 
8687    // equal care. 
8788    // 
8889    // https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/how-to/configure-custom-ranking 
89-     export   function   getCustomRanking ( )  { 
90+     getCustomRanking ( )  { 
9091        return  [ 
9192
9293            // https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/how-to/configure-custom-ranking/#configure-custom-ranking-with-the-api 
@@ -95,12 +96,12 @@ import * as page from "./page";
9596            // https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/how-to/boost-or-penalize-some-records/#using-the-api 
9697            "desc(boosted)" , 
9798        ] ; 
98-     } 
99+     } , 
99100
100101    // Rules are explicit instructions that apply fine-grained control over how certain queries are handled. 
101102    // https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/ 
102103    // https://www.algolia.com/doc/api-reference/api-methods/save-rule 
103-     export   function   getRules ( )  { 
104+     getRules ( )  { 
104105        return  [ 
105106
106107            // When the query is for "cloud", deliver the Pulumi Cloud overview page as the top result. 
@@ -207,4 +208,5 @@ import * as page from "./page";
207208                } , 
208209            } , 
209210        ] ; 
210-     } 
211+     } , 
212+ } ; 
0 commit comments