13 報

Share this post

開發者週報 #106 Swift 後悔集

www.ethanhuang13.com

開發者週報 #106 Swift 後悔集

Apple/iOS 開發者的一週大小事 2021/08/23-2021/08/29

13
Aug 29, 2021
1
Share this post

開發者週報 #106 Swift 後悔集

www.ethanhuang13.com

13的話

Swift Concurrent 確定會往回支援 iOS 13 囉。不過開發應該還需要一段時間。

這禮拜東西滿多的,我廢話寫少一點。

(看前一期 · 回首頁)


🧪 iOS 15 Beta 7

  • Xcode 13 Beta 5 沒更新

  • iOS 15 Beta 7

  • watchOS 8 Beta 7

  • tvOS 15 Beta 7

  • macOS Monterey Beta 5 沒更新

🎉Swift Concurrent backport to iOS 13 確定插旗

但我覺得應該來不及 Xcode 13 正式版。

✈️TestFlight for Mac

看起來是用 SwiftUI 寫的。需要 macOS 12 Monterey。

Twitter avatar for @stroughtonsmith
Steve Troughton-Smith @stroughtonsmith
It looks like TestFlight for Mac is built using SwiftUI, for those keeping track at home. I hope they have a better reason than that to not back-deploy it to macOS 11 😅
3:52 AM ∙ Aug 25, 2021
55Likes2Retweets

我自己實測是可以用,但 Public Link 還不支援。

📧iCloud+ 自訂電子郵件網域功能開放測試

一個 iCloud 帳號可以用五個域名。網域太多不知道怎麼辦的可以試試(?)

⭕️Runloop Mode 的 .default 與 .common 究竟有什麼不同

我入行 iOS 工程師這麼多年第一次搞懂(文件沒寫這麼清楚)。

Twitter avatar for @qdoug
Douglas Hill @qdoug
When using Timer or CADisplayLink I’m always confused if I want the common or default RunLoop Mode. Summary: .default — only runs when touches are not being tracked .tracking — only runs when touches are being tracked .common — runs whether touches are being tracked or not
3:50 PM ∙ Aug 23, 2021
189Likes30Retweets
Twitter avatar for @qdoug
Douglas Hill @qdoug
A *common* bug is that a timer or display link isn’t firing while scrolling. Fix this by changing the run loop mode from default to *common*.
3:51 PM ∙ Aug 23, 2021
22Likes2Retweets

🤔 Swift Regret 之 AnyObject method dispatch

前 Swift team 工程師 Jordan Rose 寫了一些「後悔」Swift 設計方向的推文。純粹學術討論。不過 AnyObject 這個特別長,還順便複習了 Objective-C 的基本觀念。看完你應該能明白,Swift 有很多缺點跟它的包袱有關。

請自己點開看全整串。或是聽 weak self podcast 82: Swift 後悔集 講解。

Twitter avatar for @UINT_MIN
Jordan Rose @UINT_MIN
Swift regret: AnyObject method dispatch I bet a lot of people don’t know that you can call methods on AnyObject, as long as they’re ObjC methods. TLDR: I think you shouldn’t have been able to. But how did that feature end up in the language to begin with?
10:05 PM ∙ Aug 25, 2021
122Likes16Retweets
Twitter avatar for @UINT_MIN
Jordan Rose @UINT_MIN
As I’ve mentioned *many* times, Swift had to be as good as ObjC at making most Cocoa apps, or people wouldn’t use it no matter how good the new stuff was. That’s why it’s got *so* much in the way of ObjC interop, compared to C (just okay) or C++ (still not supported).
10:05 PM ∙ Aug 25, 2021
12Likes1Retweet
Twitter avatar for @UINT_MIN
Jordan Rose @UINT_MIN
So we included this ability to call any known method on AnyObject. We could only support ObjC methods for this, because Swift methods don’t work by message sending. But even so.
10:05 PM ∙ Aug 25, 2021
9Likes1Retweet
Twitter avatar for @UINT_MIN
Jordan Rose @UINT_MIN
But separate from that, I think we could have gotten away with not implementing AnyObject method dispatch, and telling people to use protocols instead, or make an ObjC helper function to do the actual call.
10:06 PM ∙ Aug 25, 2021
21Likes1Retweet

🖥Catalyst Sample Code Roundup

今天就來寫 Mac app 吧!

📦Swift Atomics 1.0

既然是 1.0 就表示可以拿來用了吧~

🤝 Apple 與美國開發者對 App Store 支持事業發展並維持良好用戶體驗的更新內容達成共識

美國有一場開發者對 Apple 的集體訴訟。和解的狀況來說,對開發者基本上沒有任何實質變化,新聞稿也只是漂亮話,所以這條新聞我沒有放在很前面。

新聞稿裡順便宣布了 News Partner Program,對新聞業開發者倒是比較重要。

對整件事有興趣的話,可以看一下 Ryan Jones 的一系列推文。但我覺得看我摘的這幾推就夠了:

Twitter avatar for @rjonesy
Ryan Jones @rjonesy
22. Ah ha, Apple’s view is super clear now: - this lawsuit is stupid, we’ll crush you, you know it - but we don’t want to fight devs - so here is $100M and some through-away “changes” so that you can save face …they’re probably right. Very very right.
5:54 PM ∙ Aug 27, 2021
30Likes8Retweets
Twitter avatar for @rjonesy
Ryan Jones @rjonesy
23. Ah, this letter explains everything: - Apple was gonna win - so getting anything is a win for the dev - and Apple just wants it over - so here’s the min. possible money and “change” Dev gets to show big number and “change”. Apple gets to stop publicly fighting their devs.
Image
6:03 PM ∙ Aug 27, 2021
30Likes8Retweets

喔對了,比較好笑的是協助開發者打官司的律師要抽 30%🤣

Twitter avatar for @rjonesy
Ryan Jones @rjonesy
16. Annnnd there it is: The lawyers will get paid OUT OF THE SMALL DEVELOPERS ASSISTANCE FUND. $30M of $100M of the SMALL DEVELOPERS ASSISTANCE fund goes to the lawyers. 🤣😆😭 I can’t. This is just too good.
Image
3:25 AM ∙ Aug 27, 2021
340Likes94Retweets

🤪Random Tweets

浪費才能的 Neil 又來了(稱讚意味)

Twitter avatar for @neilsardesai
Neil Sardesai @neilsardesai
🌀 Sunday #uxdesign tip — dragging the pointer across long distances can be a chore. Give people a shortcut by incorporating portals into your user interface #ux #ui #uiux
4:27 PM ∙ Aug 22, 2021
2,002Likes300Retweets

這也是浪費才能

Twitter avatar for @PabloRochat
Pablo Rochat @PabloRochat
diy screensaver
3:25 PM ∙ Aug 24, 2021
5,055Likes1,318Retweets

喬喬梗圖多

Twitter avatar for @joe_trash_talk
{{an idiot sandwich}} @joe_trash_talk
@ethanhuang13 @superbil 「業主們啊!把你們的尾款都給我吧!」
元気玉 悟空 ドラゴンボール GIF
11:39 AM ∙ Aug 24, 2021

夢到的

Twitter avatar for @Deirenwu
Darren @Deirenwu
@joe_trash_talk 技工都一樣拉 再補充就有了不是嗎 重要的是甲板的狀況看來很棒 這表示船長一定是對的 進水肯定是技工偷懶 叫他們在船底挖個洞都能挖到進水 這種冗員太多當然要砍 跳船的只是不理解我們進入偉大航道的遠大目標 (虛構對白 如有雷同純屬意外
6:43 AM ∙ Aug 25, 2021

我的 SwiftUI 就是這樣偷練的(?)

Twitter avatar for @ios_memes
A meme page to check while Xcode is indexing files @ios_memes
Image
11:34 AM ∙ Aug 25, 2021
478Likes56Retweets

應該不至於吧?😅

Twitter avatar for @LeoNatan
Leo Natan @LeoNatan
Swift regret: Swift The end. 😂
12:06 PM ∙ Aug 26, 2021

我也是!

Twitter avatar for @onevcat
onevcat @onevcat
Objective-C 的水平已经退化到小学生级别了...
1:50 PM ∙ Aug 26, 2021

🎙weak self podcast 82: Swift 後悔集

「weak self 是兩個 iOS 工程師,週五下班後想打遊戲但還是來錄音給其他 iOS 工程師的 podcast 節目」

💼職缺/履歷交流區

  • 浪LIVE Sr. iOS Engineer

如果你有 iOS 相關職缺或是求職履歷想要刊登在開發者週報,請見關於。

Share this post

開發者週報 #106 Swift 後悔集

www.ethanhuang13.com
Comments
TopNewCommunity

No posts

Ready for more?

© 2023 ethanhuang13
Privacy ∙ Terms ∙ Collection notice
Start WritingGet the app
Substack is the home for great writing