-
Notifications
You must be signed in to change notification settings - Fork 13
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
Inconsistency with lower & upper #28
Comments
As discussed, potential solutions:
So all the actual solutions kind of suck. Additionally, I can't really think of a reasonable use case where you'd say "oh, hmm, I need to check whether everything in this string is lowercase" - the only situations I can think of are ones where you'd want to actually convert the string to lowercase anyway. So I'm inclined to say that we should just accept this incompatibility ( |
On further thought, I believe option 3 might not be so bad after all. The thing is that there are more tests in Jinja2, and many of them do make sense in Ginger, like for example the So here's how I think it should work:
|
ginger
decided that there is no difference between functions, tests and filters. Unfortunately, there is a clash for the tests and filterslower
andupper
:In jinja2:
|upper
returns an uppercased string which is always truthyis upper
returns true only if the string is already uppercasedThe same goes for
lower
respectivelyThis blocks #18
The text was updated successfully, but these errors were encountered: