All Projects → WillieWangWei → Swiftui Tutorials

WillieWangWei / Swiftui Tutorials

Licence: mit
A code example and translation project of SwiftUI. / 一个 SwiftUI 的示例、翻译的教程项目。

Programming Languages

swift
15916 projects

Projects that are alternatives of or similar to Swiftui Tutorials

Example Ios Apps
 A curated list of Open Source example iOS apps developed in Swift. An amazing list for people who are beginners and learning ios development and for ios developers who need any example app or feature.
Stars: ✭ 461 (-76.86%)
Mutual labels:  ios-app, ios-demo, xcode, ios-ui
NYTimes-iOS
🗽 NY Times is an Minimal News 🗞 iOS app 📱 built to describe the use of SwiftSoup and CoreData with SwiftUI🔥
Stars: ✭ 152 (-92.37%)
Mutual labels:  ios-app, combine, swiftui, swiftui-example
Swiftcocoadsl
An easy way to write iOS UI
Stars: ✭ 103 (-94.83%)
Mutual labels:  ios-app, ios-demo, ios-ui
Autoinch
优雅的iPhone全尺寸/等比例精准适配工具
Stars: ✭ 395 (-80.17%)
Mutual labels:  ios-app, ios-demo, ios-ui
Hush
Noiseless Browsing – Content Blocker for Safari
Stars: ✭ 1,987 (-0.25%)
Mutual labels:  ios-app, swiftui, swiftui-example
SwiftyIllustrator
A tool for quickly converting Adobe Illustrator shapes into SwiftUI code.
Stars: ✭ 26 (-98.69%)
Mutual labels:  swiftui, swiftui-example, swiftui-animations
Php Best Practices Zh cn
PHP Best Practices(中译版)
Stars: ✭ 261 (-86.9%)
Mutual labels:  chinese, translation, chinese-translation
The Road To Learn React Chinese
《React 学习之道》The Road to learn React (简体中文版) | 最简单,且最实用的 React 实战教程。
Stars: ✭ 1,631 (-18.12%)
Mutual labels:  chinese, translation, tutorial
CoordinatorSwiftUI
A simple project to test the implementation of Coordinator Pattern using SwiftUI.
Stars: ✭ 28 (-98.59%)
Mutual labels:  watchos, combine, swiftui
Iosproject
iOS project of collected some demos for iOS App, use Objective-C
Stars: ✭ 5,357 (+168.93%)
Mutual labels:  ios-app, ios-demo, ios-ui
Microservices
Microservices from Design to Deployment 中文版 《微服务:从设计到部署》
Stars: ✭ 4,637 (+132.78%)
Mutual labels:  chinese, translation, chinese-translation
Springboot
Spring Boot chinese document. Spring Boot 2.1.5 中文文档
Stars: ✭ 703 (-64.71%)
Mutual labels:  chinese, translation, chinese-translation
BarChart
SwiftUI Bar Chart
Stars: ✭ 156 (-92.17%)
Mutual labels:  watchos, swiftui, swiftui-example
Iosproject
IOS综合项目,完善的框架,路由模块化设计,集成科大讯飞SDK方便iOS基本输入控件实现语音辅助输入,UI效果参照京东APP,JS与OC交互,ionic跨平台开发,MQTT 协议,即时通讯协议,视屏播放,跑马灯效果 仿美团地图定位,城市收索, 友盟分享,基础动画 增加FCUIID帮助类,引导页功能模块,照片上传 ,UIView自定义导航栏,文件下载,Masonry 案例,fmdb,数据库,sqlite,百度地图,二维码,照片上传,照片上传有进度,列表倒计时,H5和原生交互,自定义各种弹框,常见表单类型,人脸识别,列表加载图片,列表拖拽,日历操作,导航条渐变,核心动画,动画特效等等
Stars: ✭ 291 (-85.39%)
Mutual labels:  ios-app, ios-demo, ios-ui
Tasky
Tasky is a task management app made with SwiftUI.
Stars: ✭ 22 (-98.9%)
Mutual labels:  ios-app, swiftui, swiftui-example
Stringz
A lightweight and powerful editor for localizing iOS, macOS, tvOS, and watchOS applications.
Stars: ✭ 440 (-77.91%)
Mutual labels:  translation, xcode, watchos
CombineUnsplash
A sample project exploring MVVM pattern with SwiftUI/Combine, using Unsplash API (via Picsum.photos API)
Stars: ✭ 25 (-98.74%)
Mutual labels:  combine, swiftui, swiftui-example
swiftui-mapkit
SwiftUI meets MapKit
Stars: ✭ 17 (-99.15%)
Mutual labels:  combine, swiftui, swiftui-example
Teachyourselfcs Cn
TeachYourselfCS 的中文翻译 | A Chinese translation of TeachYourselfCS
Stars: ✭ 11,772 (+490.96%)
Mutual labels:  translation, tutorial, chinese-translation
Cocoaasyncsocket demo
基于AsyncSocket搭建即时通讯体系 . 包含TCP连接 , 消息发送 , 消息接收 , 心跳处理 ,断网重连 , 消息超时 , 消息分发 , 数据库结构设计 , 消息丢失等 . 以及UI设计, 文本表情消息/语音消息/图片消息/视频消息/文件消息/撤回消息/提示语消息的实现思路讲解
Stars: ✭ 981 (-50.75%)
Mutual labels:  ios-app, ios-demo, ios-ui

构建示例项目需要以下环境:

  • macOS 10.15 Catalina 或更高
  • Xcode 11.1 或更高

概述

对于初步学习和使用 SwiftUI 的开发者来说,官方教程无疑是最好的范例。它以构建一个 App 为脉络,串联出了 SwiftUI 重要的知识点,并主动抛出开发中一些常见的问题,然后用 SwiftUI 给出了解决方案。通过阅读此教程,你将逐步获得使用 SwiftUI 开发 App 的技能和思想。

此项目为 SwiftUI Tutorials 的翻译及代码示例,具体内容请翻阅:

🎉 SwiftUI 教程(中文)

项目中的代码为完成所有教程后的最终成品,你可以直接体验多种 SwiftUI 特性。另外,你也可以在每个教程章节中下载对应的起始和完成代码。

完成本教程,你将获得一个这样的 App 以及一套精彩的 SwiftUI 代码:

平台 预览
iOS
watchOS
macOS

觉得不错?给个 Star 或 Follow 👌

更新日志

版本 内容
v1.0.0 完成初版
v1.0.1 同步官方文档
增加成品预览
v1.0.2 同步官方文档
优化翻译,修复翻译错误,让阅读更流畅
增加了代码高亮
标记出了代码修改范围,便于上下文对比
v1.0.3 新增章节《创建 watchOS App》
修复代码bug
增加 watchOS App 成品预览
v1.0.4 同步官方文档
v1.0.5 添加 Wiki 子模块
v1.0.6 新增章节《创建 macOS App》

调整

图片

为了优化阅读体验,部分图片加上了 #000000 50% 10 Blur 的阴影。

视频

由于 GitHub Wiki 的限制,所有视频已转码成 GIF

代码

在实际编码中,由于本地环境和官方教程不一致,导致部分方法的声明和调用方式、代码风格等与官方教程有细微出入,例如:

官方教程:

.
.
.
struct MapView: UIViewRepresentable {
    func makeUIView(context: Context) -> MKMapView {
        MKMapView(frame: .zero)
    }
}
.
.
.

这里的 UIViewRepresentable 是一个协议,它的声明中包含一个 associatedtype :

/// The type of `UIView` to be presented.
associatedtype UIViewType : UIView

在开发中,给此 associatedtype 赋值后 Xcode 对方法的签名补全会有变化,最终写作:

.
.
.
struct MapView : UIViewRepresentable {
    
    typealias UIViewType = MKMapView
    
    func makeUIView(context: UIViewRepresentableContext<MapView>) -> MKMapView {
        return MKMapView(frame: .zero)
    }
}
.
.
.

如此修改不再一一列举,只需记得此类修改不会改变原教程的构建结果即可,不必过于纠结。

微信技术群

SwiftUI 代表未来构建 App 的方向,欢迎加群一起交流技术,解决问题。

加群现在需要申请了,可以先加我微信,备注 "SwiftUI",我会拉你进群。

Stargazers over time

Sparkline

Stargazers over time

License

This project is licensed under the MIT License - see the LICENSE.md file for details.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].