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

DOM之事件捕获,冒泡,代理 #15

Open
chenshuhong opened this issue Aug 26, 2019 · 0 comments
Open

DOM之事件捕获,冒泡,代理 #15

chenshuhong opened this issue Aug 26, 2019 · 0 comments
Labels

Comments

@chenshuhong
Copy link
Owner

chenshuhong commented Aug 26, 2019

参考文章
一个完整的JS事件流是从window开始,最后回到window的一个过程
事件流被分为三个阶段捕获过程、目标过程、冒泡过程
addEventListener,第二个参数标识时候捕获,默认冒泡,即false,
利用事件冒泡可以实现事件委托

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

No branches or pull requests

1 participant