0

How to use a conditional with the empty method

Hello entrepreneurs, receive a cordial greeting from me. I am making a code that consists of dragging a paragraph and dropping it on an <div> element. Now what I need is that when I perform this event, an alert is displayed confirming the event. https://code.sololearn.com/Wb0J5wPOLcU3/?ref=app

17th Jul 2020, 4:10 PM
Holger Edud Angulo Castillo
Holger Edud Angulo Castillo - avatar
2 Respostas
0
You can try creating a boolean variable that evaluates to true when your event is completed and a then a condition that checks when that variable is equal to true. if(it happens) { iscomplete = true; } if(iscomplete=true) { alert("drag and drop succesfully completed") ; } you can add some other stuff, its your code...
17th Jul 2020, 4:37 PM
Tekashi69{Oliseh}
Tekashi69{Oliseh} - avatar
0
Holger Edud Angulo Castillo You can add an alert statement inside your drop() function.
17th Jul 2020, 4:47 PM
Hanuma Ukkadapu
Hanuma Ukkadapu - avatar