I’m trying to create a alert using jQuery. But the problem is it is not a blocking call. I need to call this in a loop after checking some cases. If the user has entered some wrong content at first though a text essay, i need to present user to fix one line after checking errors.
Is there any way to block coding without using while loops or anything.
There is no way in JavaScript to make a blocking call. There is no wait()/sleep() in JavaScript. You need to break up the logic into two steps.