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

Methods for checking if a URL component exists #80

Open
roback opened this issue Feb 3, 2016 · 5 comments
Open

Methods for checking if a URL component exists #80

roback opened this issue Feb 3, 2016 · 5 comments

Comments

@roback
Copy link
Member

roback commented Feb 3, 2016

A Twingly::URL#trd? method would have been nice to have in https://github.com/twingly/norrstrom/pull/102 instead of having to do !url.trd.empty?.

A #path? method could also be added, and possibly others too.

@jage
Copy link
Contributor

jage commented Feb 3, 2016

Great idea!

@dentarg
Copy link
Collaborator

dentarg commented Feb 3, 2016

I think so too.

@walro
Copy link
Contributor

walro commented Feb 3, 2016

Indeed!

@dentarg
Copy link
Collaborator

dentarg commented Sep 20, 2016

@walro
Copy link
Contributor

walro commented Sep 20, 2016

Maybe it would be suited with some metaprogramming here, extend every component method with a predicate ditto that's pretty much implemented as !property.empty?.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants