๋ณธ๋ฌธ ๋ฐ”๋กœ๊ฐ€๊ธฐ

๋ถ„๋ฅ˜ ์ „์ฒด๋ณด๊ธฐ

(159)
Struct / Class ๋ž€ ๋ฌด์—‡์ธ๊ฐ€? Struct๊ตฌ์กฐ์ฒด์˜ ๊ฒฝ์šฐ ๊ฐ’ ํƒ€์ž…์ด๋‹ค. ๊ฐ’ ํƒ€์ž…(Value Type) ์€ ํ•ด๋‹น ํƒ€์ž…์˜ ์ธ์Šคํ„ด์Šค๊ฐ€ ๋ณต์‚ฌ๋  ๋•Œ ์ธ์Šคํ„ด์Šค์˜ ์‹ค์ œ ๋ฐ์ดํ„ฐ๊ฐ€ ๋ณต์‚ฌ๋œ๋‹ค. ์ด๋Š” ํ•˜๋‚˜์˜ ์ธ์Šคํ„ด์Šค๋ฅผ ์ˆ˜์ •ํ•˜๋”๋ผ๋„ ๋‹ค๋ฅธ ๋ณต์‚ฌ๋ณธ์— ์˜ํ–ฅ์„ ๋ฏธ์น˜์ง€ ์•Š๋Š” ๊ฒƒ์„ ์˜๋ฏธํ•œ๋‹ค. ๊ฐ’์˜ ์ €์žฅ์€ ์Šคํƒ์—์„œ ์ผ์–ด๋‚˜๋ฉฐ, ๋ฉ”๋ชจ๋ฆฌ์—์„œ ์ž๋™์œผ๋กœ ์ œ๊ฑฐ๋œ๋‹ค. ํ•ด๋‹น ์ธ์Šคํ„ด์Šค๋ฅผ let์œผ๋กœ ์„ ์–ธ ์‹œ ์ €์žฅ ์†์„ฑ์ด ์ „๋ถ€ ์ƒ์ˆ˜๋กœ ์ €์žฅ๋œ๋‹ค. ๋˜ ๋ฉค๋ฒ„์™€์ด์ฆˆ ์ด๋‹ˆ์…œ๋ผ์ด์ €๋ฅผ ์ž๋™์œผ๋กœ ์ œ๊ณตํ•˜๋ฉฐ, ๋ฉ”์„œ๋“œ ๋‚ด์—์„œ ์†์„ฑ ๋ณ€๊ฒฝ์ด ์›์น™์ ์œผ๋กœ ๋ถˆ๊ฐ€๋Šฅํ•˜๋‹ค. ๋‹ค๋งŒ mutating ํ‚ค์›Œ๋“œ๋กœ ๋ณ€๊ฒฝ์ด ๊ฐ€๋Šฅํ•˜๊ธด ํ•˜๋‹ค. ์†Œ๋ฉธ์ž๋Š” ์กด์žฌํ•˜์ง€ ์•Š์œผ๋ฉฐ ์ƒ์†์ด ๋ถˆ๊ฐ€๋Šฅํ•˜๋‹ค.struct Student { var name: String var gender: String init(name: String, gender: Str..
[Archive Error] PhaseScriptExecution failed with a nonzero exit code Workaround is to update all the generated ...-frameworks.sh files to add the -f flag to the call to readlink. In other words, need to replace: source="$(readlink "${source}")" with source="$(readlink -f "${source}")" Seems this is CocoaPods issue... Upgrade from xCode 14.2 to 14.3 Ph… | Apple Developer Forums Hi, we are seeing the same problem with Xcode betas 14E5197f, 14E5207e and 14E5215g. Wh..
Design Pattern in Swift [ ์ƒ์„ฑ ํŒจํ„ด ] 1) ๋นŒ๋” ํŒจํ„ด (Builder Pattern) - ์–ด๋–ค Product ์™€ ์ด๋ฅผ ๋งŒ๋“œ๋Š” Builder๋กœ ๊ตฌ์„ฑ - ์ด ํŒจํ„ด์€ Swift์— ๊ทธ๋ ‡๊ฒŒ๊นŒ์ง€ ์œ ํšจํ•œ ํŒจํ„ด์€ ์•„๋‹˜ -> ๋Œ€๋ถ€๋ถ„ ์ดˆ๊ธฐํ™” ๋ฉ”์„œ๋“œ์™€ ํ”„๋กœํผํ‹ฐ ๊ธฐ๋ณธ๊ฐ’์„ ํ™œ์šฉํ•˜์—ฌ ํ•ด๊ฒฐ ๊ฐ€๋Šฅ - ํ”„๋กœํผํ‹ฐ์˜ ๊ฐœ์ˆ˜๊ฐ€ ๊ต‰์žฅํžˆ ๋งŽ์•„์ง€๊ณ  ๋ณต์žกํ•ด์ง€๋Š” ๊ฒฝ์šฐ์— ์œ ์šฉ struct MacBook { let color: String let memory: Int let storage: String let hasTouchBar: Bool } class MacBookBuilder { private var color = "Space Gray" private var memory = 16 private var storage = "256GB" private var hasTouchBar = fal..
[SLP] 4์ผ์ฐจ TODO 1. idToken & FCM Token ๋ฐ›์•„์˜ค๋Š” ๊ธฐ๋Šฅ ๊ตฌํ˜„ 2. Google Info Plist ๋ณ€๊ฒฝ ํ›„ idtoken ๊ธฐ๋ฐ˜์œผ๋กœ Insumnia ์™€ Swagger๋ฅผ ํ†ตํ•ด ์„œ๋ฒ„์— ์ž˜ ๋ฐ˜์˜๋˜๋Š” ์ง€ ํ™•์ธ ์˜ค๋Š˜์€ ๋“œ๋””์–ด ๋ฏธ๋ฃจ๊ณ  ๋ฏธ๋ฃจ๋˜ Google Info Plist ๋ณ€๊ฒฝํ•˜๊ณ  ์„œ๋ฒ„ ํ†ต์‹  ๋ถ€๋ถ„์„ ํ…Œ์ŠคํŠธํ•ด๋ณด์•˜๋‹ค. ๊ทธ๋™์•ˆ ๋ญ”๊ฐ€ Google Info Plist ๋ฅผ ๋ณ€๊ฒฝํ•˜๋ฉด ํฐ์ผ์ด ๋‚  ๊ฑฐ ๊ฐ™์•„์„œ ๋ฏธ๋ฃจ๊ณ  ์žˆ์—ˆ๋Š”๋ฐ, ์ „ํ™”๋ฒˆํ˜ธ ์ธ์ฆ๋„ ์ž˜ ๋˜๊ณ  ํ† ํฐ๋“ค๋„ ์ž˜ ๋ฐ›์•„์™€์ง€๋Š” ๊ฑฐ ๊ฐ™์•„์„œ ์˜ค๋Š˜์€ ์‹œ๋„ํ•ด๋ณด์•˜๋‹ค. ์›๋ž˜ ์ฒ˜์Œ์—๋Š” Plist ๋ณ€๊ฒฝ์„ ์•ˆํ•˜๊ณ , Insumnia์—์„œ 401 ์—๋Ÿฌ๋งŒ ๊ณ„์† ๋– ์„œ ์‚ฝ์งˆ๋งŒ ํ•˜๊ณ  ์žˆ์—ˆ๋Š”๋ฐ ์•Œ๊ณ ๋ณด๋‹ˆ ๋‹น์—ฐํ•˜๊ฒŒ๋„ Plist ๋ณ€๊ฒฝ์„ ํ•œ ํ›„์— ๋ฐœ๊ธ‰ ๋ฐ›์€ ํ† ํฐ์œผ๋กœ ์„œ๋ฒ„ ํ†ต์‹ ์„ ํ•ด์•ผ ๋˜๋Š” ๊ฒƒ์ด์—ˆ๋‹ค .... ๋™๊ธฐ๋ถ„์ด ์•ˆ๋„์™€์ฃผ..
[SLP] 3์ผ์ฐจ TODO 1. ์˜จ๋ณด๋”ฉ ํ™”๋ฉด๋ถ€ํ„ฐ ํšŒ์›๊ฐ€์ž…๊นŒ์ง€ ๋””ํ…Œ์ผํ•œ UI๊นŒ์ง€ 80% ์™„์„ฑ 2. Color & Font Extension ๋งŒ๋“ค๊ธฐ 3. ํšŒ์›๊ฐ€์ž… UI ๋””ํ…Œ์ผํ•˜๊ฒŒ ์™„์„ฑ [SWIFT] UITextField์˜ Under Line ์ถ”๊ฐ€ํ•˜๊ธฐ(๋ฐ‘์ค„) [์›๋ฆฌ] ํ…์ŠคํŠธ ํ•„๋“œ์˜ ๋ชจ์–‘์€ ๋Œ€๋ถ€๋ถ„ ์•„๋ž˜์™€ ๊ฐ™๋‹ค. ์Šคํƒ€์ผ์˜ ๊ฒฝ์šฐ 4๊ฐœ๋กœ ์ œ๊ณต๋˜๊ธดํ•˜๋Š”๋ฐ.. ๊ทธ ๊ฒƒ๋„ ๋ง˜์— ๋“ค์ง€ ์•Š์„๋•Œ, ๋ฐ‘ ์ค„์„ ๊ธ‹๊ณ  ์‹ถ์„๋•Œ! ์•„๋ž˜์™€ ๊ฐ™์ด ์ด๋Ÿฐ ๊ฒฝ์šฐ์—” ์Šคํ† ๋ฆฌ๋ณด๋“œ์˜ ๋ฉ”๋‰ด๋กœ๋Š” ํ•ด๊ฒฐ g-y-e-o-m.tistory.com viewdidlayoutsubview ๋ฅผ ์ด์šฉํ•ด์„œ TextField์— ๋ฐ‘์ค„์„ ๋„ฃ๋Š” ๊ธฐ๋Šฅ์„ ๊ตฌํ˜„ํ•ด๋ณด์•˜๋‹ค. ๋งŒ๋“ค๋ฉด์„œ Viewdidload ์‹œ์ ์—์„œ๋Š” ๋ฐ‘์ค„์ด ์•ˆ๊ทธ์–ด์ง€๋Š” ์ด์Šˆ๊ฐ€ ์žˆ์–ด์„œ ์œ„ ๋ธ”๋กœ๊ทธ๋ฅผ ์ฐธ๊ณ ํ•˜์—ฌ ํ•ด๊ฒฐํ–ˆ๋‹ค. ์ด ๋ถ€๋ถ„์€ ์ข€ ๋” ๊ณต๋ถ€๊ฐ€ ํ•„์š”ํ•  ๊ฒƒ ๊ฐ™๋‹ค...
[SLP] 2์ผ์ฐจ TODO 1. ์ธ์ฆ์ฝ”๋“œ ์ž๋™์™„์„ฑ ๊ธฐ๋Šฅ 2. ํšŒ์›๊ฐ€์ž… UI ๋ ˆ์ด์•„์›ƒ ์žก๊ธฐ ์ธ์ฆ์ฝ”๋“œ ์ž๋™์™„์„ฑ ๊ธฐ๋Šฅ ๊ตฌํ˜„ํ–ˆ๋‹ค. ์ƒ๊ฐ๋ณด๋‹ค ๊ฐ„๋‹จํ•œ ์ฝ”๋“œ์—ฌ์„œ ๊นœ์ง ๋†€๋ž๋˜ .... ์˜ค๋Š˜์€ ๊ฐ‘์ž‘์Šค๋Ÿฝ๊ฒŒ ์ผ์ด ์ƒ๊ฒจ๋ฒ„๋ ค๊ฐ€์ง€๊ณ  ๊ฐœ๋ฐœ์— ์‹œ๊ฐ„์„ ๋งŽ์ด ํˆฌ์ž๋ฅผ ๋ชปํ–ˆ๋˜ ๋‚ ์ด์—ˆ๋‹ค. ๊ทธ๋ž˜์„œ ๊ฐ„๋‹จํ•˜๊ฒŒ ํ•  ์ˆ˜ ์žˆ๋Š” ํšŒ์›๊ฐ€์ž… ์ชฝ UI ๋ฅผ ์™„์„ฑํ–ˆ๋‹ค.
[SLP] 1์ผ์ฐจ TODO 1. ์˜จ๋ณด๋”ฉ ํ™”๋ฉด layout ๊ตฌํ˜„ 2. ์ธ์ฆ๋ฌธ์ž ์ „์†ก ๊ธฐ๋Šฅ ๊ตฌํ˜„ 3. ์ธ์ฆ์ฝ”๋“œ ๊ธฐ๋ฐ˜ ํšŒ์› ์œ ๋ฌด ํ™•์ธ ๊ธฐ๋Šฅ ๊ตฌํ˜„ ์˜ค๋Š˜์€ Figma ์‹œ์•ˆ์„ ๋ณด๊ณ  ์ „์ฒด์ ์œผ๋กœ ์–ด๋–ป๊ฒŒ ์„œ๋น„์Šค๊ฐ€ ๊ตฌํ˜„๋˜์–ด ์žˆ๋Š”์ง€ ํ™•์ธํ•œ ํ›„, Firbase Auth๋ฅผ ํ†ตํ•ด ํšŒ์›๊ฐ€์ž… ์œ ๋ฌด๋ฅผ ํŒ๋‹จํ•˜๋Š” ์ „ํ™”๋ฒˆํ˜ธ ์ธ์ฆ์„ ๊ตฌํ˜„ํ–ˆ๋‹ค. Firebase๋ฅผ ์ฒ˜์Œ๋ถ€ํ„ฐ ๋‹ค์‹œ ์„ค์ •ํ•˜๊ณ , xcode์™€ ์—ฐ๊ฒฐํ•˜๋Š” ๊ณผ์ •์ด ์˜ค๋žœ๋งŒ์ด์–ด์„œ ๊ทธ๋Ÿฐ์ง€ ์ค‘๊ฐ„์ค‘๊ฐ„์— ํ—ท๊ฐˆ๋ฆฌ๋Š” ๋ถ€๋ถ„์ด ๊ฝค ์žˆ์—ˆ๋‹ค. ์˜ค๋Š˜ ์ƒˆ๋กญ๊ฒŒ ํ•™์Šตํ•œ ๋ถ€๋ถ„์€ Firebase Auth๋ฅผ ํ™œ์šฉํ•ด์„œ ์ „ํ™”๋ฒˆํ˜ธ ์ธ์ฆ์„ ๋ฐ›๋Š” ๋ถ€๋ถ„์ด์—ˆ๋‹ค. ์ง€๊ธˆ๊นŒ์ง€์˜ Firebase ์™€ ์กฐ๊ธˆ ๋‹ค๋ฅธ ๋ถ€๋ถ„์ด ์žˆ์—ˆ๋‹ค๋ฉด, URL Types ์— Google Info Plist์˜ REVERSED_CLIENT_ID๋ฅผ ๋ณต์‚ฌํ•ด์„œ ๋ถ™์—ฌ๋„ฃ๋Š” ๊ณผ์ •์ด ์žˆ์–ด์•ผ ํ•˜๋Š” ๊ฒƒ์ด์—ˆ๋‹ค. ์ „ํ™”๋ฒˆ..
[ํšŒ๊ณ ] ๋ถํŠธ๋ฆฝ AppStore ์ถœ์‹œ ํšŒ๊ณ  ๊ฐœ๋ฐœ ์†Œ์š” ๊ธฐ๊ฐ„ : 22.09.13 - 22.09.29 (์•ฝ 16์ผ) ์‚ฌ์šฉํ•œ ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ ( ์ด 9๊ฐœ ) - Alamofire - FSCalendar - IQKeyboardManager - KingFisher - Mantis - Realm - Snapkit - SwiftyJSON - Toast ๋งก์€ ์—ญํ•  - ๊ธฐํš / ๋””์ž์ธ / ๊ฐœ๋ฐœ ๋ชจ๋‘ ๊ธฐํš ๋‹จ๊ณ„ ์ด๋ฒˆ ์ถœ์‹œ ํ”„๋กœ์ ํŠธ์—์„œ ํ•˜๊ณ  ์‹ถ์—ˆ๋˜ ์•„์ด๋””์–ด๊ฐ€ ์ƒ๊ฐ๋ณด๋‹ค ๋งŽ์•˜๋Š”๋ฐ, ๊ทธ์ค‘์—์„œ๋„ ๋‚ด๊ฐ€ ์ •๋ง๋กœ ํ‰์†Œ์— ๋ถˆํŽธํ•จ์„ ๋Š๋ผ๊ณ  ์ด๋ฅผ ํ•ด๊ฒฐํ•˜๊ณ  ์‹ถ์—ˆ๋˜ ๋ฌธ์ œ๋ฅผ ์•ฑ์˜ ์ฃผ์ œ๋กœ ์‚ผ๋Š” ๊ฒƒ์ด ์ข‹๊ฒ ๋‹ค๋Š” ์ƒ๊ฐ์ด ๋“ค์–ด์„œ ์ด์ „๋ถ€ํ„ฐ ๊ผญ ์•ฑ์œผ๋กœ ๋งŒ๋“ค๊ณ  ์‹ถ์—ˆ๋˜ ๋…๋ฆฝ์„œ์  ํ๋ ˆ์ดํŒ… ์•ฑ์„ ๋งŒ๋“ค์–ด์•ผ๊ฒ ๋‹ค๋Š” ์ƒ๊ฐ์ด ๋“ค์–ด ๋ถํŠธ๋ฆฝ์„ ๊ธฐํšํ•˜๊ฒŒ ๋˜์—ˆ๋‹ค. ๊ทธ๋ž˜์„œ ์ผ๋‹จ ๊ธฐํš ๋‹จ๊ณ„์—์„œ๋Š”, ์ง€๋„ ๊ธฐ๋ฐ˜์œผ๋กœ ๊ฐ€์žฅ ๋‹ค์–‘ํ•œ ๋…๋ฆฝ์„œ์ ..