error-message-index
error-message-index copied to clipboard
No convenient programmatic access to the search
I want to set up a search macro for my browser's URL bar, so I can type err blah and have it go visit https://errors.haskell.org/?q=blah.
There doesn't seem to be any way to do that, because the search bar is an embedded JS thing with no API.
Ultimately there ought to be a real API where a program can post a string or error code and get back a description or a URL, but that would be a separate bug report. All I am currently requesting is a distinct URL for each search.
Thanks for the feedback!
Do you know a good way to implement this without any server-side programming? Having the site be a simple static site really simplifies the maintenance and hosting, and I'd like to preserve that if possible.
For instance, what if the search field were pre-populated with the contents of a GET parameter? Would that help?
The Javascript can look at the query parameters and, if there are any, prepopulate the input field with the query parameters instead of with the placeholder text.
On Thu, Oct 20, 2022 at 2:21 PM David Thrane Christiansen < @.***> wrote:
Thanks for the feedback!
Do you know a good way to implement this without any server-side programming? Having the site be a simple static site really simplifies the maintenance and hosting, and I'd like to preserve that if possible.
For instance, what if the search field were pre-populated with the contents of a GET parameter? Would that help?
— Reply to this email directly, view it on GitHub https://github.com/haskellfoundation/error-message-index/issues/350#issuecomment-1285963805, or unsubscribe https://github.com/notifications/unsubscribe-auth/AZEQG2I77ANBZLU23XHW6MDWEGERTANCNFSM6AAAAAARKMVBY4 . You are receiving this because you authored the thread.Message ID: @.***>
Right - would this be sufficient for your use case?
Yes, I think so. I can tell the browser to visit https://errors.haskell.org/?q=blah, then the code in tableFilter.js can see the q=blah in the query parameters, fill the input field with blah, and do the search as if I had typed blah manually.
On Thu, Oct 20, 2022 at 3:26 PM David Thrane Christiansen < @.***> wrote:
Right - would this be sufficient for your use case?
— Reply to this email directly, view it on GitHub https://github.com/haskellfoundation/error-message-index/issues/350#issuecomment-1286033588, or unsubscribe https://github.com/notifications/unsubscribe-auth/AZEQG2I6YWKBULJ7MNHXSHDWEGMGXANCNFSM6AAAAAARKMVBY4 . You are receiving this because you authored the thread.Message ID: @.***>
Great to hear!
I have a similar problem, which might have a separate solution. I want a link to ALL GHCup errors. That doesn't have to be done with the filter, we could just have a subpage for grouping.
This has been fixed by #387 If there is still some missing feature please shout :)