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

enhancement(search website): Add page tags to search index #8261

Merged
merged 9 commits into from Jul 20, 2021

Conversation

lucperkins
Copy link
Contributor

@lucperkins lucperkins commented Jul 13, 2021

This PR updates the search indexing logic for the new vector.dev to include per-page tags. It also performs some basic input sanitation by ensuring that there's no extraneous whitespace in section titles. Including tags should improve the search sensitivity and give us more per-page levers that we can use to influence result sets.

Please note that this renames what was previously the tags field to hierarchy to make room for what I feel is a more intuitively named tags field.

@lucperkins lucperkins changed the title enhancement(search): Add page tags to search index enhancement(search website): Add page tags to search index Jul 13, 2021
@netlify
Copy link

netlify bot commented Jul 16, 2021

✔️ Deploy Preview for vector-project ready!

🔨 Explore the source changes: f361610

🔍 Inspect the deploy log: https://app.netlify.com/sites/vector-project/deploys/60f73dee85d7390008bb9fb6

😎 Browse the preview: https://deploy-preview-8261--vector-project.netlify.app

@lucperkins lucperkins changed the base branch from master to website July 19, 2021 22:04
@lucperkins lucperkins requested review from a team and JeanMertz and removed request for a team July 19, 2021 22:04
@lucperkins lucperkins requested review from zsherman and removed request for JeanMertz July 20, 2021 20:47
Copy link
Contributor

@zsherman zsherman left a comment

Choose a reason for hiding this comment

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

Should the changes to the file source be in here?

@lucperkins
Copy link
Contributor Author

lucperkins commented Jul 20, 2021

@zsherman That was a relic of us changing the branching scheme for the website. Fixed via rebase.

Luc Perkins added 9 commits July 20, 2021 14:19
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
@lucperkins lucperkins merged commit 9479ea8 into website Jul 20, 2021
@lucperkins lucperkins deleted the search-index-page-tags branch July 20, 2021 21:26
lucperkins pushed a commit that referenced this pull request Jul 21, 2021
* Add tags to indexing and trim titles

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Change meta element name to keywords

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Update JS search widget to use hierarchy instead of tags

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix Typescript type issue in indexing script

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Try different TS syntax for undefined

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix or error in script

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix more or/default issues

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Remove unused dependencies and variables and refactor section recursion

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Add .env file to gitignore

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

Co-authored-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
lucperkins pushed a commit that referenced this pull request Jul 21, 2021
* Add tags to indexing and trim titles

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Change meta element name to keywords

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Update JS search widget to use hierarchy instead of tags

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix Typescript type issue in indexing script

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Try different TS syntax for undefined

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix or error in script

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix more or/default issues

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Remove unused dependencies and variables and refactor section recursion

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Add .env file to gitignore

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

Co-authored-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
lucperkins pushed a commit that referenced this pull request Jul 21, 2021
* Add tags to indexing and trim titles

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Change meta element name to keywords

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Update JS search widget to use hierarchy instead of tags

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix Typescript type issue in indexing script

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Try different TS syntax for undefined

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix or error in script

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix more or/default issues

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Remove unused dependencies and variables and refactor section recursion

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Add .env file to gitignore

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

Co-authored-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
lucperkins pushed a commit that referenced this pull request Jul 22, 2021
* Add tags to indexing and trim titles

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Change meta element name to keywords

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Update JS search widget to use hierarchy instead of tags

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix Typescript type issue in indexing script

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Try different TS syntax for undefined

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix or error in script

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix more or/default issues

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Remove unused dependencies and variables and refactor section recursion

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Add .env file to gitignore

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

Co-authored-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
lucperkins pushed a commit that referenced this pull request Jul 28, 2021
* Add tags to indexing and trim titles

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Change meta element name to keywords

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Update JS search widget to use hierarchy instead of tags

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix Typescript type issue in indexing script

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Try different TS syntax for undefined

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix or error in script

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Fix more or/default issues

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Remove unused dependencies and variables and refactor section recursion

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

* Add .env file to gitignore

Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>

Co-authored-by: Luc Perkins <luc.perkins@datadoghq.com>
Signed-off-by: Luc Perkins <luc.perkins@datadoghq.com>
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.

None yet

2 participants