app 优化-提高ios app性能的建议和技巧

来源:互联网 发布:单片机设计大赛 编辑:程序博客网 时间:2024/05/22 05:16

基础

1. 用ARC去管理内存(Use ARC to Manage Memory)

2.适当的地方使用reuseIdentifier(Use a reuseIdentifier Where Appropriate)

3.尽可能设置视图为不透明(Set View as Opaque When Possible)

4.避免臃肿的XIBs(Avoid Fat XiBs)

5.不要阻塞主进程(Don't Block the Main Thread

6.调整图像视图中的图像尺寸(Size Images to Image Views

7.选择正确集合(Choose the Correct Collection

8.启用Gzip压缩(Enable GZIP Compression


中级

9. 重用和延迟加载视图(Reuse and Lazy Load Views

10.缓存,缓存,缓存(Cache,Cache,Cache

11.考虑绘图(Consider Drawing

12.处理内存警告(Handle Memory Warnings

13.重用大开销对象(Reuse Expensive Objects

14.使用精灵表(Use Sprite Sheets

15.避免重复处理数据(Avoid Re-Processing Data

16.选择正确的数据格式(Choose the Right Data Format

17.适当的设置背景图片(Set  Background Images Appropriately

18.减少你的网络占用(Reduce Your Web Footprint 

19.设置阴影路径(Set the Shadow Path

20.你的表格视图Optimize Your Table Views

21.选择正确的数据存储方式(Choose Correct Data Storage Option


高级

22.加速启动时间(Speed up Launch Time

23.使用自动释放池(Use AutoRelease Pool

24.缓存图像(Cache Images-Or not

25.尽可能避免日期格式化器(Avoid Date Formatters Where Possible 


0 0
原创粉丝点击