Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Swift 学习 #14

Open
ShannonChenCHN opened this issue Apr 23, 2017 · 9 comments
Open

Swift 学习 #14

ShannonChenCHN opened this issue Apr 23, 2017 · 9 comments

Comments

@ShannonChenCHN
Copy link
Owner

ShannonChenCHN commented Apr 23, 2017

The Swift Programming Language(3.1) 学习笔记

@ShannonChenCHN
Copy link
Owner Author

ShannonChenCHN commented Apr 23, 2017

平时工作中用的一直是 Objective-C,如何跟上 Swift 的脚步?

  • 学习官方教程 The Swift Programming Language,先照着敲一遍,然后总结知识点,再通过实践来巩固
  • 照着官方示例程序做一个完整的项目 Start Developing iOS Apps (Swift)
  • 大概读一下 Big Nerd Ranch 出品的 Swift Programming,上面有几个 Demo 可以跟着敲一下
  • 在写 Objective-C 代码时,可以尝试往Swift 的角度去思考,比如 nullability,判断对象是否为空是用 if (object == nil) 而不是 if (object)
  • 平时在用 Objective-C 写开源代码时,可以尝试着用 Swift 也写一遍
  • 自己尝试用 Swift 写一个 App,可以是纯 Swift,也可以是 Objective-C 和 Swift 混编
  • 可以学习一下比较优秀的开源项目,以及开源 APP的代码
  • objc.io 出品的 Swift 系列文章可以读一下
  • 可以到 Twitter 上关注一下 Swift 方面的动态,毕竟国外还是比较积极的
  • Swift 周报 Swift Developments Newsletter

@ShannonChenCHN
Copy link
Owner Author

ShannonChenCHN commented Apr 23, 2017

对于使用 Objective-C 的开发者,学习 Swift 要注意什么?

@ShannonChenCHN
Copy link
Owner Author

ShannonChenCHN commented Apr 23, 2017

学习 Swift 有什么比较好的资料吗?

@ShannonChenCHN
Copy link
Owner Author

ShannonChenCHN commented Apr 25, 2017

@ShannonChenCHN
Copy link
Owner Author

ShannonChenCHN commented Apr 28, 2017

常见问题

  1. 如何查看 Mac 上的 Swift 版本?
    方式一:
    在 Xcode 中查看
Project ► (Select Your Project Target) ► Build Settings ► (Type 'swift_version' in the Search bar) Swift Compiler Language ► Swift Language Version ► Click on Language list to open it (and there will be a tick mark on any one of list-item, that will be current swift version).

方式二:
通过命令行查看:

$ xcrun swift -version

参考 How do I see which version of Swift I'm using?

@ShannonChenCHN ShannonChenCHN changed the title 【专题】Swift 学习 Swift 学习 Sep 11, 2017
@ShannonChenCHN
Copy link
Owner Author

ShannonChenCHN commented Sep 11, 2017

@ShannonChenCHN
Copy link
Owner Author

ShannonChenCHN commented Sep 21, 2017

@ShannonChenCHN
Copy link
Owner Author

Swift ABI 稳定性问题

见同类问题:编译、链接相关

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant