event.preventDefault()

event.preventDefault()

event.preventDefault()Returns: undefined

Description: If this method is called, the default action of the event will not be triggered.

For example, clicked anchors will not take the browser to a new URL. We can use 登录查看完整内容