Thank you very much But can u give me code example about 3. After subpackaging, static resources are also subpacked. Please pay attention to the distinction. Only the resources used in the subpackaging are transferred to the subpackaging, and the images shared by the subpackaging can only be placed in the main package.
从简单到复杂
1.删除无效的静态资源,使用TinyPng压缩静态资源
2.代码分包,tabbar的页面作为主包,tabbar对应的页面以及关联的二级页面作为一个分包,比如5个tabbar页面,就做5个分包
3.分包之后静态资源也随着分包,要注意区分,只有分包里用到的资源才转移到分包,分包共用的图片只能放主包。
4.图片按大小排序,上传至服务器后使用https链接替换,然后删除本地图片资源
5.减少使用一些非必要的三方npm包,手写方法替换实现
You can translate it yourself
But can u give me code example about
3. After subpackaging, static resources are also subpacked. Please pay attention to the distinction. Only the resources used in the subpackaging are transferred to the subpackaging, and the images shared by the subpackaging can only be placed in the main package.
where are you from?