Skip to content

Remove $.datepicker.log #543

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

Closed
wants to merge 1 commit into from
Closed

Conversation

nicofrand
Copy link

jQuery ui 1.10.0+ does not implement $.datepicker.log anymore.
This replaces all datepicker.log calls by console.log (which is the same thing actually).

@trentrichardson
Copy link
Owner

Thanks for pointing that out. A couple thoughts. When some browsers don't have the console open they can throw errors to the user (which may not be preferred). Perhaps they should be wrapped with:

if(window.console)
    console.log('error text...');

Just to keep things more DRY maybe we should create a $.timepicker.log() to do this. However I wouldn't mind knowing why datepicker quit with $.datepicker.log(), maybe we need to follow their lead?

Also this pull request was to master, these changes will need to go through the dev branch first.

Trent

@nicofrand
Copy link
Author

Datepicker was not testing window.console in their own method, but I
guess that would not be too much.
For the DRY part, this could be useful if, for example, you allowed the
user to report errors in the console or not (that might be really
practical).

I asked on IRC if anyone knew why they did remove it since it is not
mentionned anywhere (upgrade guide, blog post, website) but someone
answered me
that since it was not documented, the method could be removed anytime
they wanted without warnings.

Sorry for the wrong branch, this was my first Git experience…

Nicolas

Le 29/01/2013 20:11, Trent Richardson a écrit :

Thanks for pointing that out. A couple thoughts. When some browsers
don't have the console open they can throw errors to the user (which
may not be preferred). Perhaps they should be wrapped with:

if(window.console)
console.log('error text...');

Just to keep things more DRY maybe we should create a
$.timepicker.log() to do this. However I wouldn't mind knowing why
datepicker quit with $.datepicker.log(), maybe we need to follow their
lead?

Also this pull request was to master, these changes will need to go
through the dev branch first.

Trent


Reply to this email directly or view it on GitHub
#543 (comment).

Cordialement,

Frandeboeuf </nicofrand/> Nicolas, http://blog.breizhogeek.com

htt://blog.breizhogeek.com

@trentrichardson
Copy link
Owner

No problem, I did a quick find replace and did this on the dev branch. Thanks for checking!

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

Successfully merging this pull request may close these issues.

2 participants