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

Search for NonElementParentNode #407

Open
KAction opened this issue Apr 12, 2020 · 2 comments
Open

Search for NonElementParentNode #407

KAction opened this issue Apr 12, 2020 · 2 comments

Comments

@KAction
Copy link

KAction commented Apr 12, 2020

I was trying to figure out how to create object of type NonElementParentNode, since it is referenced in type of selectElementById. The most oblivious search query:

https://pursuit.purescript.org/search?q=NonElementParentNode

showed only the fact that it is foreign data. What I actually wanted is that I can convert HTMLDocument to it link.

Attempt to search by function signature a -> NonElementParentNode (hello, hoogle) showed totally irrelevant results, like abs :: forall a. Ord a => Ring a => a -> a.

@klntsky
Copy link
Contributor

klntsky commented Apr 12, 2020

<shameless plug>

Use starsuit instead. It works differently than pursuit: it allows you to make queries like A -> NonElementParentNode (yes, with capital A). This query can be described as "something concrete -> NonElementParentNode", rather than "literally forall a. -> NonElementParentNode".

Check out the implementation if you want to understand how exactly search results are sorted.

I use both pursuit and starsuit, they both have pros and cons at processing different types queries.

@hdgarrood
Copy link
Collaborator

Thanks for the report. I agree that with a query of a -> NonElementParentNode, the candidate HTMLDocument -> NonElementParentNode should score higher than forall a. Ord a => Ring a => a -> a.

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

No branches or pull requests

3 participants