javascript - When refactoring, the original object becomes a js module (js file), so how should the previously bound events be written now?
高洛峰
高洛峰 2017-06-30 09:59:03
0
1
654

Refactor the old code, modularize it, and split a large js file into many js files. The original namespace object has been split into js files. So where should the events that were previously bound to the object be bound now? Is it written as a function and can be called when an event is triggered?

高洛峰
高洛峰

拥有18年软件开发和IT教学经验。曾任多家上市公司技术总监、架构师、项目经理、高级软件工程师等职务。 网络人气名人讲师,...

reply all(1)
学习ing

I don’t quite understand the question, but do you think the observer pattern is feasible?

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!