How to use code formatter in Xcode for Swift?

后端 未结 9 891
Happy的楠姐
Happy的楠姐 2021-01-31 07:25

Xcode code formatter Swift

I\'m trying to auto format my code written in Swift. It\'s necessary if you\'re working in team and using CVS and don\'t want

9条回答
  •  北荒
    北荒 (楼主)
    2021-01-31 07:57

    Xcode and Swift 2.0: Per file, Cmd-A then Ctl-I. Ctl-I works for what is highlighted, Cmd-A highlights all. Just be careful not to accidentally delete all your source after the Ctl-A!

提交回复
热议问题