問題描述
Xcode 7.3、Swift 2.2 故事板極慢 (Xcode 7.3, Swift 2.2 Storyboards Extremely Slow)
我正在開發一個巨大的應用程序,並且自從更新到 Xcode 7.3 後,在 Storyboard 中做任何事情都像糖蜜一樣!!
大約一個月前,我使用一個 HUGE Storyboard 的速度大致相同,所以我把項目分成 5 個獨立的故事板,哈利路亞,快了一百倍!但是現在,更新後,竟然分到了7;盡可能慢!我將要備份,然後嘗試重新創建一個大的,然後再次備份,然後再次分割 ‑ 看看是否有任何作用;但我很懷疑。
有人知道如何解決這個問題,或者最新的更新有什麼問題嗎?
參考解法
方法 1:
Well, not a great solution but, all I can determine is that; if the number of items and constraints in the view gets over a certain amount (using Xcode 7.3), the speed suddenly drops horribly. So what I ended up having to do with this last storyboard (8 of 8) is to take a slide out side pane full of buttons and subviews, and place it in a container view ‑ so that I could give it its own VC and thereby make it a stand alone 9th storyboard.
Not a great solution that's for sure, especially since I had to tie all of the buttons and methods to the parent view controller. I was lucky in this event in that the parent view (my main app map) is a single instance occurrence so I was able to reference it at launch, and merely prefix my former methods with the reference. If this was not so, I guess I would have to have done some serious protocol / delegation.
So, a proper solution (or 'fix' if it is Xcode's doing) is still wanting :)
(by Aroniousness、Aroniousness)