-
Notifications
You must be signed in to change notification settings - Fork 171
jqueryui.com issue #94 #350
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
Conversation
@@ -356,6 +356,12 @@ $(function() { | |||
plugin = parts[ 3 ], | |||
demo = parts[ 4 ].substring( 0, parts[ 4 ].length - 5 ); | |||
|
|||
var str1 = "default"; | |||
var str2 = "effect"; | |||
if ( demo.localeCompare(str1) == 0 && plugin.localeCompare(str2) == 0 ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a fairly roundabout way to do this check, why not just plugin === "effect" && demo === "default"
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought this would be easily understandable to others
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is much less understandable than the direct comparison.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should I change it to plugin === "effect" && demo === "default"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Deffinitly direct comparison lets not obfuscate this by using locale.
@scottgonzalez Did the final thing |
@@ -341,7 +341,7 @@ $(function() { | |||
/* | |||
* jqueryui.com | |||
*/ | |||
$(function() { | |||
$(function() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Extra whites space at end of line. No need to change this line.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@arschmitz sorry that was by mistake :P
Thanks, but while reviewing this I found a better solution that doesn't require hard-coding exceptions into the script. |
@scottgonzalez What is that? |
You can see it in the commit that closed this PR: 0196a65 |
No description provided.