์ ์ฌ์๊ฐ์ด๋ ํด๊ทผ ํ์ ์งฌ์งฌ์ด ๊ฐ์๋ฅผ ๋ณด๋ฉฐ swift๋ก ๋ฉ๋ชจ์ฅ์ ๋ง๋ค์๊ณ core Data ๊ตฌํ ์ ๊น์ง ๊ณต๋ถํ๋ค.
๋ณด๊ณ ๋ฐ๋ผ ํ๋ ๊ฑด ์ฝ์ง๋ง ์ดํด๊ฐ ์์ ํ ๋์ง ์์ #1 - #6๊น์ง์ ๊ฐ์ ๋ด์ฉ์ ์ ๋ฆฌํด๋ณด๋ ค๊ณ ํ๋ค.
1. ํ๋ก์ ํธ ์์ฑ ๋ฐ ์ค์ ํ๊ธฐ
2. Main UI ๊ตฌ์ฑํ๊ธฐ
2-1. ViewController.swift - Delete
2-2. Main.stroyBoard View - Delete
2-3. Open Library (command + Shift + L)
2-4. Navigation Controller ์ถ๊ฐ
3. ์ฒ์ ์์ ํ๋ฉด ์ค์ ํ๊ธฐ
3-1. Main.storyBoard ํด๋ฆญ
3-2. Navigation Controller๋ฅผ ํด๋ฆญํ๋ค ์ฐ์ธก Is Initial View Controller ์ฒดํฌ
4. ๋ค๋น๊ฒ์ด์ ๋ฐ ๊ตฌ์ฑํ๊ธฐ
4-1. Title ๋ณ๊ฒฝํ๊ธฐ
4-2. Large Titles ์ฒดํฌํ๊ธฐ
4-3. Bar ๋ฒํผ ์ถ๊ฐ ๋ฐ System Item add๋ก ๋ณ๊ฒฝํ๊ธฐ
4-5. ๊ฒฐ๊ณผ ํ์ธ
5. Memo Class ์์ฑํ๊ธฐ
5-1. Memo Class ์์ฑ
5-2. ๋๋ฏธ ๋ฐ์ดํฐ ๋ฑ๋ก
//
// Model.swift
// Memo2
//
// Created by truemac on 2021/08/22.
//
import Foundation
class Memo {
var content : String
var insertDate : Date
init(content : String) {
self.content = content
insertDate = Date()
}
static var dummyMemoList = [
Memo(content: "์ฒซ๋ฒ์งธ ๋ฉ๋ชจ ๋ฑ๋ก"),
Memo(content: "๋๋ฒ์งธ ๋ฉ๋ชจ ๋ฑ๋ก")
]
}
6. Table View Cell ๊ตฌ์ฑํ๊ธฐ
6-1. Style - Subtitle
6-2. Subtitle Color ๋ณ๊ฒฝ
6-3. identifier ๋ฑ๋ก
7. Table VC ์์ฑํ๊ธฐ
7-1. Cocoa Touch Class ์์ฑ
7-2. Class๋ช ๋ณ๊ฒฝ
7-3. ์์ฑ๋ Classํ์ผ ํด๋์ค๋ช ๋ณต์ฌ
7-4. StoryBoard sene ์ ํ
7-5. Custom Class - Class์ ๋ณต์ฌํ ํด๋์ค ๋ช ๋ถ์ฌ ๋ฃ๊ธฐ
command + B ํด๋ฆญํ์ฌ ํ๋ก์ ํธ ๋น๋
๊ทธ ํ ๊ฐ๋ฐ์ (3), (4) ํธ์ผ๋ก..
https://truecode-95.tistory.com/147