当前位置:网站首页>SwiftUI 4 新功能之掌握 WeatherKit 和 Swift Charts
SwiftUI 4 新功能之掌握 WeatherKit 和 Swift Charts
2022-07-07 09:46:00 【知识大胖】
SwiftUI 4 新功能之掌握 WeatherKit 和 Swift Charts
今年在 WWDC22 上有很多令人兴奋的新框架和 API 让我们投入其中。然而,我对 WeatherKit 和 Swift Charts 感到非常兴奋,因为我们现在终于有了对天气数据和绘制数据集的原生 1 方支持。
在本文中,我们将研究如何将两者结合起来以可视化我们的天气数据。距离主题演讲已经过去了 30 个小时,所以请记住,您看到的代码可能会在接下来的几个月内发生变化。我还遇到了一些不受支持的图表命令,这些命令会引发致命错误。
Swift Charts
那么什么是 Swift 图表?它是一种在各种图表样式中轻松简单地绘制数据的方法(截至撰写本文时;不支持饼图、径向图等),还支持所有可爱的可访问性功能、动画等。
在过去,我不得不编写自己的图表或引入 3rd 方依赖项来实现这一点,即便如此,可访问性功能和动画也没有完全考虑到。
天气套件
Apple 早在 2020 年 3 月就收购了流行的 Dark Sky 天气应用程序,这让开发人员想知道什么会取代已退役的 Dark Sky API,现在我们有了官方答案。开发人员现在可以使用原生的、以隐私为中心的解决方案,而不是依赖第三方提供商。
即使在这个早期的 beta 阶段,文档也显示 API 非常全面,涵盖了一系列天气数据、警报
边栏推荐
- 通过环境变量将 Pod 信息呈现给容器
- sql里,我想设置外键,为什么出现这个问题
- 千人规模互联网公司研发效能成功之路
- Talk about SOC startup (VII) uboot startup process III
- 浙江大学周亚金:“又破又立”的顶尖安全学者,好奇心驱动的行动派
- Talk about SOC startup (x) kernel startup pilot knowledge
- 【愚公系列】2022年7月 Go教学课程 005-变量
- Qt 实现容器的DELETE的方式
- Verilog design responder [with source code]
- Half of the people don't know the difference between for and foreach???
猜你喜欢
Leetcode - interview question 17.24 maximum submatrix
Table replication in PostgreSQL
关于测试人生的一站式发展建议
The annual salary of general test is 15W, and the annual salary of test and development is 30w+. What is the difference between the two?
Electron adding SQLite database
electron添加SQLite数据库
一起探索云服务之云数据库
禁锢自己的因素,原来有这么多
Automated testing framework
How to add aplayer music player in blog
随机推荐
STM32 entry development write DS18B20 temperature sensor driver (read ambient temperature, support cascade)
千人规模互联网公司研发效能成功之路
测试优惠券要怎么写测试用例?
R语言使用magick包的image_mosaic函数和image_flatten函数把多张图片堆叠在一起形成堆叠组合图像(Stack layers on top of each other)
VIM command mode and input mode switching
Unsupervised learning of visual features by contracting cluster assignments
Android interview knowledge points
sink 消费 到 MySQL, 数据库表里面已经设置了 自增主键, flink 里面,如何 操作?
There are so many factors that imprison you
R语言使用quantile函数计算评分值的分位数(20%、40%、60%、80%)、使用逻辑操作符将对应的分位区间(quantile)编码为分类值生成新的字段、strsplit函数将学生的名和姓拆分
Eth trunk link switching delay is too high
Excel公式知多少?
聊聊SOC启动(十) 内核启动先导知识
正在運行的Kubernetes集群想要調整Pod的網段地址
请查收.NET MAUI 的最新学习资源
R语言可视化分面图、假设检验、多变量分组t检验、可视化多变量分组分面箱图(faceting boxplot)并添加显著性水平、添加抖动数据点(jitter points)
聊聊SOC启动(九) 为uboot 添加新的board
對比學習之 Unsupervised Learning of Visual Features by Contrasting Cluster Assignments
Learning notes | data Xiaobai uses dataease to make a large data screen
[question] Compilation Principle