当前位置:网站首页>2021.4.15 note the difference between let, const and VaR in ES6

2021.4.15 note the difference between let, const and VaR in ES6

2022-06-25 04:25:00 Robin Luo Bing

1、export default And export const The difference between  https://www.cnblogs.com/meijifu/p/12990055.html

2、module.exports And exports,export And export default The relationship and difference between   https://www.cnblogs.com/fayin/p/6831071.html

3、vuex Inside this.$store.dispatch and this.$store.commit Usage and difference  https://www.cnblogs.com/meiyanstar/p/13566625.html

4、ES6 in let、const and var The difference between

https://www.cnblogs.com/sunala/p/9878123.html

https://www.cnblogs.com/zhaoxiaoying/p/9031890.html

https://www.runoob.com/js/js-let-const.html  difference : function 、 loop 、 block {}、 The difference between the scopes formed

5、 Detailed explanation uniapp Implementation of global variables of  https://www.jb51.net/article/203836.htm

6、   setStorageSync and setStorage The difference between

setStorage And setStorageSync The difference is that :setStorage It's asynchronous , and setStorageSync It's synchronous .
When your subsequent operations must depend on modification storage Later data , That is to say, your subsequent operations are based on modification storage After success , Then you need to use synchronization , That is to say setStorageSync, Otherwise, when the following operations are executed , The data used is still not updated .
When you do not need to modify the following operations storage data , There is no need to synchronize immediately , At this point, you can choose to use asynchronous , That is to say setStorage , Because it takes time to manipulate memory , Often not as fast as code .
With Sync( Sync , meanwhile ) The end is synchronous cache , The difference between them is , Asynchrony does not block the current task , The synchronization cache cannot continue until the synchronization method is processed .
Popular point theory , Asynchrony is whether the protection is saved successfully or not , The program will continue to execute . When the synchronization is saved successfully , Will execute the following code . Use asynchronous , Performance will be better ; And use synchronization , Data will be more secure .

原网站

版权声明
本文为[Robin Luo Bing]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/02/202202210534569317.html