-
Notifications
You must be signed in to change notification settings - Fork 41
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
Add generalized repetition #23
Comments
How would It seems like it may not make sense with different selectors and that you would need something with a type like Another, though less intuitive option, is to abuse
|
Presumably, it would return the empty list, since no single element has both selectors. I hadn't thought of the |
Closing out for now, if you feel like the current documentation isn't extensive or visible enough please reopen. |
matchAll :: Scraper a b -> Scraper a [b]
, generalizinghtmls
,attrs
,texts
, andchroots
from their singular forms.This is useful in case I want to
matchAll (html "a" <* (attr "title" "a" >>= \x -> guard (somePredicate x)))
.(Yes, I actually ran into this.)
many
doesn't solve the problem because it's alternation;replicateM
and friends don't solve the problem because eachScraper
looks from the current spot.The text was updated successfully, but these errors were encountered: