일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | |||
5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 |
- pubspec
- protocol
- github
- reetcode
- pubspec.yaml
- SwiftGen
- enumerations
- swiftlint
- UIAccessibility
- algorithm
- Extentsion
- Swift
- basic
- Widget
- listview
- COMMIT
- flutter
- Leetcode
- Equatable
- it
- GIT
- keyWindow
- dart
- ToDoRim
- OSLog
- xcode
- tip
- designPattern
- toyproject
- IOS
- Today
- Total
목록Swift (55)
개발자 수니
💡 문제 (Easy) Middle of the Linked List - LeetCode Can you solve this real interview question? Middle of the Linked List - Given the head of a singly linked list, return the middle node of the linked list. If there are two middle nodes, return the second middle node. Example 1: [https://assets.leetcode. leetcode.com Given the head of a singly linked list, return the middle node of the linked list...
📌 이번 글은 Xcode에서 주석과 퀵헬프 사용 방법 입니다. 주석 - 주석 생성 단축키 : command[⌘] + / 한 줄 주석 // 한 줄 주석 여러 줄 주석 /* 여러 줄 주석 */ 중첩 주석 /* 여러 줄 주석 안쪽에 /* 여러 중첩 주석 가능 // 한 줄도 가능 */ 여기도 주석! */ 문서화 주석 // MARK: - 문서화 주석 /// 한 줄 문서화 주석 /** 여러 줄 문서화 주석 */ 퀵헬프 (Quick Help) - 코드 기능 설명서 - 퀵헬프 보는 방법 : option[⌥] + 원하는 코드 클릭 or command[⌘] + option[⌥] + [3] - 퀵헬프 생성 단축키 : command[⌘] + option[⌥] + / 퀵헬프를 위한 마크업 예시 /// 오류 타입의 열거형 ///..
💡 문제 (Easy) Fizz Buzz - LeetCode Can you solve this real interview question? Fizz Buzz - Given an integer n, return a string array answer (1-indexed) where: * answer[i] == "FizzBuzz" if i is divisible by 3 and 5. * answer[i] == "Fizz" if i is divisible by 3. * answer[i] == "Buzz" if i is leetcode.com Given an integer n, return a string array answer (1-indexed) where: - answer[i] == "FizzBuzz" if..
💡 문제 (Easy) Richest Customer Wealth - LeetCode Can you solve this real interview question? Richest Customer Wealth - You are given an m x n integer grid accounts where accounts[i][j] is the amount of money the i th customer has in the j th bank. Return the wealth that the richest customer has. A custom leetcode.com You are given an m x n integer grid accounts where accounts[i][j] is the amount o..
iOS13에서 status bar 사이즈를 구할 때 사용하던 statusBarFrame이 deprecated 되었습니다. 'statusBarFrame' was deprecated in iOS 13.0: Use the statusBarManager property of the window scene instead. 📌 이번 글은 iOS 13에서 statusBarFrame 경고를 해결하여 상태바 높이를 구하는 소스입니다. static let STATUS_HEIGHT: CGFloat = UIApplication.shared.windows.filter {$0.isKeyWindow}.first?.windowScene?.statusBarManager?.statusBarFrame.height ?? 0 // 상태바 높이
iOS13에서 가장 앞 쪽에 배치된 윈도우를 구하는 keyWindow가 deprecated 되었습니다. 'keyWindow' was deprecated in iOS 13.0: Should not be used for applications that support multiple scenes as it returns a key window across all connected scenes 📌 이번 글은 iOS 13에서 keyWindow 경고를 해결하는 Extension 소스입니다. UIApplication+Exntension.swift import UIKit extension UIApplication { /** # keyWindowInConnectedScenes - Note: iOS 13 keyWindow..
📌 이번 글은 Keychain으로 안전한 데이터를 저장하는 방법입니다. 이 글에서는 SwiftKeychainWrapper 라이브러리를 사용할 예정입니다. Keychain 앱에서 사용자 비밀번호, 토큰과 같은 민감함 정보를 저장해야 할 때, 안전하게 저장할 필요가 있습니다. iOS는 암호화된 컨테이너로 Keychain이 존재하며, 민감함 데이터를 암호화하고 복호화하며 재사용하는 행위를 보다 쉽고 안전하게 사용할 수 있게끔 Keychain Services API를 제공합니다. SwiftKeychainWrapper Keychain Services API를 보다 편하고 안전하게 이용할 수 있게끔 해주는 라이브러리 입니다. GitHub - jrendel/SwiftKeychainWrapper: A simple wr..
📌 이번 글은 UserDefaults 값을 반환하고, 저장하는 방법입니다. UserDefaults UserDefaults는 앱의 '데이터 저장소' 입니다. 여러 타입(Any)의 객체를 저장할 수 있고, 사용자 기본 설정과 같은 단일 데이터 값을 저장하고자 할 때 적합합니다. 저는 종종 자동 로그인 여부(isAutoLogin)를 저장할 때 사용합니다. UserDefaults 값 저장 let defaults = UserDefaults.standard defaults.set(true, forKey: "isAutoLogin") UserDefaults 값 반환 let defaults = UserDefaults.standard if let object = defaults.object(forKey: "isAutoLo..