Skip to content

Commit 871d1a0

Browse files
committed
fix #5168
1 parent 9f17885 commit 871d1a0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Reports/2025/#355-2025.10.20.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,9 @@ Live Activities 的核心是帮助用户快速获取关键动态信息,减少
6767

6868
[@DylanYang](https://github.com/Dylan19Yang):iOS 17 引入的 AutoFillUI 框架使得在使用 UITextField 时会发生不预期的内存泄漏,当 UITextField 成为第一响应者且用户离开视图时就会发生。由于在 SwfitUI 中 TextField 可以通过 .environmentObject() 保持对大型对象图的引用,因此在 SwiftUI 中内存泄漏的问题会更严重一点。对问题起因和绕过方式感兴趣的同学可以阅读本文作进一步了解。
6969

70+
### 🐎 [How to hide a view in a screenshot](https://www.swiftwithvincent.com/blog/how-to-hide-a-view-in-a-screenshot)
71+
72+
[@david-clang](https://github.com/david-clang):作者利用 UITextField 在 isSecureTextEntry = true 时自带的“截图防泄露”机制,将需要隐藏的视图嵌入其安全子视图中,从而实现内容在截图与录屏时自动隐藏的效果,作者还用 UIViewRepresentable 封装出 .hideInScreenshot() 修饰符,让 SwiftUI 也能轻松实现防截图效果。
7073

7174
## 工具
7275

0 commit comments

Comments
 (0)