Weekly Comment
On December 25th last year, my blog was officially launched after a redesign. A significant change in this revision was the provision of articles in both Chinese and English versions, and I also stopped updating articles on other technical platforms in China. A month later, from December 25th to January 23rd, the blog's traffic data showed significant changes:
According to Google Analytics:
UV (Unique Visitors) reached 14K, an increase of 156% compared to the previous 30 days.
PV (Page Views) reached 35K, up by 99.6%.
According to Baidu Analytics:
UV reached 18.3K, an increase of 234%.
PV reached 35K, up by 224%.
It is noteworthy that the proportion of Chinese visitors dropped from 75% to 33%, meaning that non-Chinese users now make up the majority.
The significant increase in traffic to the new blog was unexpected, and the trend seems set to continue according to the statistics.
My initial intention in creating the blog was to improve myself while sharing and interacting with more friends. Seeing more and more readers browsing my articles naturally fills me with joy. Although I hope my articles can be seen by more friends, I will still maintain my original intention in future creations, focusing on topics that interest me, are helpful to me and others, and are content-rich.
I look forward to exchanging ideas and progressing together with friends who are interested in SwiftUI, Core Data, and SwiftData through my articles.
Previous Issue|Newsletter Archive
If you find this weekly newsletter or my blog helpful, I would greatly appreciate your consideration of making a donation through Patreon, or Buy Me a Coffee.
Originals
Exploring SwiftUI Property Wrappers: @AppStorage, @SceneStorage, @FocusState, @GestureState and @ScaledMetric
In this article, we will continue to explore property wrappers in SwiftUI: @AppStorage
, @SceneStorage
, @FocusState
, @GestureState
, and @ScaledMetric
. These property wrappers cover various aspects including data persistence, interactive response, accessibility features, and multi-window support, providing developers with succinct and practical solutions.
This article is the second part of the series exploring SwiftUI property wrappers. The first part is Exploring Key Property Wrappers in SwiftUI: @State, @Binding, @StateObject, @ObservedObject, @EnvironmentObject, and @Environment. The series comprises four articles, aiming to comprehensively overview the functionalities of all property wrappers in SwiftUI.
Recent Selections
Case insensitive string comparison in Swift
This article discusses various methods of performing string comparisons in Swift programming, particularly emphasizing the importance of considering case sensitivity. In conventional practice, developers might tend to simply convert strings to the same case and then compare them using ==
. However, this approach has significant limitations and can lead to performance issues. Natalia Panferova suggests more recommended methods that not only ensure the accuracy and efficiency of comparisons but also take into account the differences in users' cultural backgrounds.
Unit Test the Observation Framework
This article explores how to effectively conduct unit testing on the Observation framework in iOS 17. Jacob Bartlett points out in the article that traditional techniques used for testing @Published
properties are no longer applicable to the new Observation framework. He demonstrates this through unit tests of BeerViewModel under both Combine and Observation frameworks, revealing strategies for adapting to the new framework. Additionally, Bartlett provides a helpful utility function, waitForChanges
, designed to simplify the testing process within the Observation framework and enhance testing efficiency.
Interactive Widgets With SwiftUI
This tutorial, written by Alessandro Di Nepi and provided by Kodeco, offers a detailed guide on how to implement interactive widgets in SwiftUI. By integrating interactive widgets into an app named Trask, the article vividly demonstrates how enhancing interactivity can improve the functionality and user experience of widgets. Additionally, the tutorial delves into various types of interactive widgets, as well as the best practices to follow in designing and developing these components.
A simple fastlane setup for solo indie developers
This article provides a guide on how to set up fastlane for independent developers, aiming to automate the uploading of builds and metadata to the App Store. Jesse Squires shares his extensive experience with using fastlane in team settings, as well as his process of setting up fastlane from scratch for the first time. The main focus of the article is to offer a simple and efficient method of configuring fastlane for solo developers.
Insight on the changes to Apple policy in the EU from the Revenue Cat webinar
Recently, Apple's new App Store policy for the European Union region has garnered widespread attention. Against this backdrop, Gabrielle Earnshaw shared some key insights from the Revenue Cat webinar. The webinar discussed several important issues, including the market size affected by the new policy, risk factors under the new business terms, types of applications suitable for adopting these terms, considerations for accepting the business terms, and restrictions on app releases. This information provides a comprehensive overview of the main considerations and potential risks for independent developers and small teams adapting to the new policy.
Event
Let's visionOS 2024
The first Asian visionOS Developers Conference, "Let's visionOS Conf", co-planned by SwiftGG and XReality Zone, will kick off on March 30, 2024, in Beijing! The event will feature numerous renowned speakers from both domestic and international circles, sharing their practical experiences and industry insights!
In addition to programming technology, the conference content will also encompass product design, human-computer interaction, and commercialization, aiming to help entrepreneurs stand out quickly in the visionOS track!
We eagerly look forward to everyone's participation, whether you are an attendee, sponsor, guest speaker, or volunteer. We warmly welcome you to join us in embracing and exploring this exciting new field!
For more details, please visit the official website of the event.
肘子的话
去年 12 月 25 日,我的博客经过重新设计后正式上线。这次改版的一个重要变化是提供了文章的中英文两个版本,并且我也停止了在中国其他技术平台上更新文章。一个月后,即从 12 月 25 日至 1 月 23 日,博客的访问数据呈现出显著的变化:
根据谷歌分析:
UV(独立访客)达到 14K,相比之前的 30 天增长了 156%。
PV(页面浏览量)达到 35K,增长了 99.6%。
根据百度分析:
UV 为 18.3K,增长了 234%。
PV 为 35K,增长了 224%。
值得注意的是,中文访客从占比 75% 下降到 33%,这意味着非中文用户现在已经占据了大多数。
新博客取得如此显著的访问量增长是我没有预料到的,且从统计数字来看,这种增长趋势还将持续。
我创建博客的初衷是在提升自我的同时与更多朋友分享和交流。看到越来越多的读者浏览我的文章,我心中自然感到一丝欣喜。虽然我希望我的文章能被更多朋友看到,但在未来的创作中,我仍将保持初心,专注于我感兴趣、对我和他人有帮助、内容充实的主题。
我期待着通过我的文章与对 SwiftUI、Core Data、SwiftData 感兴趣的朋友进行交流,并共同进步。
如果您发现这份周报或我的博客对您有所帮助,可以考虑通过 爱发电,Buy Me a Coffee 支持我的创作。
原创
探讨 SwiftUI 中的属性包装器:@AppStorage、@SceneStorage、@FocusState、@GestureState 和 @ScaledMetric
在本文中,我们将继续了解 SwiftUI 中的属性包装器:@AppStorage
、@SceneStorage
、@FocusState
、@GestureState
以及 @ScaledMetric
。这些属性包装器涵盖了数据持久化、交互响应、辅助功能、多窗口支持等多个方面, 为开发者提供了简洁实用的解决方案。
这篇文章是关于探索 SwiftUI 属性包装器系列的第二部分。第一部分为 探讨 SwiftUI 中的关键属性包装器:@State、@Binding、@StateObject、@ObservedObject、@EnvironmentObject 和 @Environment。整个系列包括四篇文章,旨在全面梳理 SwiftUI 中所有属性包装器的功能。
近期推荐
Case insensitive string comparison in Swift
本文探讨了在 Swift 编程中执行字符串比较的多种方式,特别强调了考虑大小写敏感性的重要性。在常规做法中,开发者可能倾向于简单地将字符串统一转换成相同的大小写形式,然后使用 ==
进行比较。然而,此方法存在明显的局限,并且可能引发性能上的问题。Natalia Panferova 提出了更为推荐的方法,这些方法不仅确保了比较的准确性和效率,而且兼顾了用户文化背景的差异。
Unit Test the Observation Framework
这篇文章探讨了在 iOS 17 中如何有效地对 Observation 框架进行单元测试。Jacob Bartlett 在文章中指出,传统用于测试 @Published
属性的技巧已无法适用于新的 Observation 框架。他通过展示在 Combine 和 Observation 框架下对 BeerViewModel 进行的单元测试,揭示了适应新框架的测试策略。此外,Bartlett 还提供了 waitForChanges
这一实用的帮助函数,旨在简化 Observation 框架下的测试流程,有效地提高测试效率。
Interactive Widgets With SwiftUI
这篇由 Alessandro Di Nepi 撰写的教程,由 Kodeco 提供,详细介绍了在 SwiftUI 中如何实现交互式小组件的添加。通过将交互式小部件融入名为 Trask 的应用,文章生动展示了如何通过加强交互性来提升小部件的功能和用户体验。此外,教程还深入探讨了交互式小部件的各种类型,以及在设计和开发这些小部件时应遵循的最佳实践。
A simple fastlane setup for solo indie developers
本文介绍了如何为独立开发者的应用程序设置 fastlane,以自动化上传构建和元数据到 App Store。jesse squires 分享了他在以往团队工作中广泛使用 fastlane 的经验,以及他首次从头开始设置 fastlane 的过程。文章的主旨是为独立开发者提供一个简单、高效的 fastlane 配置方法。
Insight on the changes to Apple policy in the EU from the Revenue Cat webinar
近日,苹果针对欧盟地区的新 App Store 政策引发了广泛关注。在此背景下,Gabrielle Earnshaw 对 Revenue Cat 网络研讨会中的一些关键观点进行了分享。研讨会探讨了若干重要议题,包括受新政影响的市场规模、新商业条款下的风险点、适合采纳新条款的应用类型、商业条款的接受考量,以及应用发布的相关限制。这些内容为独立开发者和小型团队在适应新政策过程中的主要考虑因素和潜在风险提供了全面的概述。
活动
Let's visionOS 2024
由 SwiftGG 和 XReality Zone 共同策划的第一届亚洲 visionOS 开发者大会【Let's visionOS Conf】将于2024.3.30日在北京拉开帷幕!届时会邀请国内外多名大咖来分享他们的实战经验和行业洞见!
会议内容除了编程技术,还会包括产品设计,人机交互和商业化等内容,旨在帮助创业者们在 visionOS 赛道中尽快脱颖而出!
十分期待大家的到来,不论您是参会者,赞助商,演讲嘉宾,还是志愿者,我们都诚挚的欢迎你们与我们共同迎接和探索这个全新的领域!
详情请访问本次活动的官网。