What is the meaning of preventDefault() in HTML5 | Sololearn: Learn to code for FREE!

+1

What is the meaning of preventDefault() in HTML5

12/15/2018 2:30:13 PM

Pramod Paratabadi

2 Answers

New Answer

+1

Preventing default actions for elenents. For example, if you call this method on click event on link, browser will not go further. This behaviour is used for creating buttons etc via <a> tag. And for other purposes.