最近又把 RxSwift複習了下,寫了一個小 Demo 主要是構建網路模塊,Demo 我已經上傳,在文章末尾處可以下載,接下來就一步步去構建: 第一步(數據層):使用 ObjectMapper 構建 Model // // LoginModel.swift // RxSwiftDemo01 // // Created by macOSJack on 2024/11/5. // import
在使用xcode15創建新項目編譯時遇到的Sandbox文件寫創建權限問題,解決方案:BuildSettings中將UserScriptSanboxing設置為NO,並將ProjectFormat降級為Xcode15.0。 具體解決方法:
轉自:https://www.cnblogs.com/bridge-wuxl/p/10790888.html 影響 View 佈局區域的有以下三個屬性: self.edgesForExtendedLayout (影響View佈局區域的主要屬性) self.navigationController.navigationBar.translucent (navigationBar 是否半透明)
在使用前先倒入shared_preferences: ^2.0.15 import 'package:shared_preferences/shared_preferences.dart'; //本地持久化存儲工具類 class ShareLocalDataTool { ShareLocalDataTool._(); static Futurebool saveStringList(
/** * 路由封裝 */ class RouteUtils { RouteUtils._(); static final navigatorKey = GlobalKeyNavigatorState(); // App 根節點Context static BuildContext get context = navigatorKey.currentContext!;