Skip to content

Use hash when searching #267

New issue

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

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

Already on GitHub? # to your account

Merged
merged 1 commit into from
Dec 12, 2019

Conversation

rvsia
Copy link
Contributor

@rvsia rvsia commented Dec 12, 2019

This appends hash to algolia suggestions.

@rvsia rvsia added bug Something isn't working docs docs pull requests labels Dec 12, 2019
@rvsia rvsia requested a review from Hyperkid123 December 12, 2019 13:00
@@ -54,7 +54,7 @@ const DocSearch = () => {
handleSelected: (input, event, suggestion) => {
event.button = 0;
const resultUrl = new URL(suggestion.url);
push(resultUrl.pathname);
push(`${resultUrl.pathname}${resultUrl.hash}`);
Copy link
Member

Choose a reason for hiding this comment

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

what if the hash is undefined?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Can it be?

Copy link
Member

@Hyperkid123 Hyperkid123 Dec 12, 2019

Choose a reason for hiding this comment

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

Well that depends on the algolia crawler. We are not in control here

@Hyperkid123 Hyperkid123 merged commit c0f3941 into data-driven-forms:master Dec 12, 2019
@Hyperkid123
Copy link
Member

🎉 This PR is included in version 1.23.7 🎉

The release is available on

Demo can be found here!

@rvsia rvsia deleted the router-uses-hash branch March 5, 2020 12:33
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working docs docs pull requests released
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants