使用js闭包的好处

    使用闭包有以下几大好处:

    a:希望一个变量长期驻扎在内存中。

    b:避免全局变量的污染。

原文地址:https://www.cnblogs.com/shiyunfront/p/9804300.html