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

Please improve documentation: ajaxComplete is called before or after success/error callbacks? #1217

Open
KES777 opened this issue Dec 31, 2022 · 2 comments

Comments

@KES777
Copy link

KES777 commented Dec 31, 2022

Description

https://api.jquery.com/ajaxcomplete/
I am new to jQuery and there is not so clear: .ajaxComplete is called bofore or after success/error callbacks?

Thank you.

@mgol mgol transferred this issue from jquery/jquery Dec 31, 2022
@mgol
Copy link
Member

mgol commented Jan 11, 2023

Thanks for the report. I don't think we guarantee anything about the order here; however, in practice, the event is fired after the callbacks are called. If you use promise then/catch methods, though, note that they are async so they'll fire later.

@mgol mgol added the Discuss in Meeting Reserved for Issues and PRs that anyone would like to discuss in the weekly meeting. label Jan 11, 2023
@timmywil timmywil added help wanted and removed Discuss in Meeting Reserved for Issues and PRs that anyone would like to discuss in the weekly meeting. labels Feb 6, 2023
@timmywil
Copy link
Member

timmywil commented Feb 6, 2023

We're fine with documenting this, but we'd like to take time to make sure it's been consistent historically. If the order has ever changed, it should be noted which versions are different from others.

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

No branches or pull requests

3 participants