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

Can we make search modify the URL #2543

Open
EssamWisam opened this issue Jul 2, 2024 · 4 comments
Open

Can we make search modify the URL #2543

EssamWisam opened this issue Jul 2, 2024 · 4 comments
Labels
Format: HTML Related to the default HTML output help wanted Type: Enhancement

Comments

@EssamWisam
Copy link

EssamWisam commented Jul 2, 2024

I was willing to integrate documenter's search with an external site for one package that I'm working on.
image
However, that seems impossible because the current search implementation doesn't the URL in any way. It would be nice to have search function similar to common search engines, where the url is modified based on the input.

@mortenpi mortenpi added Type: Enhancement Format: HTML Related to the default HTML output help wanted labels Jul 3, 2024
@mortenpi
Copy link
Member

mortenpi commented Jul 3, 2024

We actually used to do that, and I think it should doable with the new search as well, where we just look at and update a special query parameter.

integrate documenter's search with an external site

Do you mean you want to be able to link to the search results? Or do you mean something else?

@EssamWisam
Copy link
Author

We actually used to do that, and I think it should doable with the new search as well, where we just look at and update a special query parameter.

integrate documenter's search with an external site

Do you mean you want to be able to link to the search results? Or do you mean something else?

Yes, to be able to link it with the link being meaningful. An example from Google:

https://www.google.com/search?q=julia+documenter

First, it can be linked and second, it allows integration with another site since any external site can do

https://www.google.com/search?q=${custom-search-term}

@mortenpi
Copy link
Member

mortenpi commented Jul 3, 2024

Pre-1.0 that used to be possible: https://documenter.juliadocs.org/v0.27/search/?q=deploydocs

I'd say we can bring this back if someone wants to take a stab at implementing it / recovering the original implementation. The only caveat is that there wouldn't be a dedicated search page, but it would probably work on every page. I guess the canonical choice can just be the root page though.

@Hetarth02
Copy link
Contributor

Happy to take a try at this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Format: HTML Related to the default HTML output help wanted Type: Enhancement
Projects
None yet
Development

No branches or pull requests

3 participants