Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Algolia search works again #682

Merged
merged 1 commit into from
Oct 20, 2023
Merged

Conversation

Jelledb
Copy link
Contributor

@Jelledb Jelledb commented Oct 20, 2023

  • I am not sure how this worked initially but I found the two indexes on Algolia and pointed to their App IDs & API Key
  • I changed the code in the Crawler so it correctly picks up headers (v1: algolia search result display issue facebook/docusaurus#6432)
  • I changed in general some of the URLs that were pointed to in the Crawler.

All in all this seems to work now. You can run yarn build:master locally and serve the build and it will work :-)

Demo: https://jmp.sh/erIJKzE9

@render
Copy link

render bot commented Oct 20, 2023

Copy link
Contributor

@tfelix tfelix left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general okay (as the key was there before anyways) but I added a remark and question if this is actually a good idea.

@@ -6,9 +6,9 @@
"scripts": {
"examples": "docusaurus-examples",
"start": "docusaurus-start",
"build:master": "DOCSEARCH_INDEXNAME='meshcloud' DOCSEARCH_APIKEY='1b6387d9fcda3cba4cdb3ffb68cde260' docusaurus-build",
"build:master": "DOCSEARCH_INDEXNAME='meshcloud' DOCSEARCH_APIKEY='aa3b874dff5c832fe2e3ed42a8062160' DOCSEARCH_APP_ID='LDDGX81P02' docusaurus-build",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

d: I hope this APIKEY is not sensitive so its okay to have it in the public repo? Not that someone can extract this key and post a own, modified search result to the service? Not sure how it works. I thought during build time it generates an index and transmits to their server? Then to have those keys here I guess could be problematic?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

The key is just for querying in frontend and is safe.

@Jelledb Jelledb added this pull request to the merge queue Oct 20, 2023
Merged via the queue into develop with commit e270b06 Oct 20, 2023
2 checks passed
@Jelledb Jelledb deleted the feature/fix-algolia-search branch October 20, 2023 13:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants