Skip to content

Coding Convention

Kyoungjin Lim edited this page Jul 21, 2021 · 1 revision

ํŒŒ์ผ๋ช… ๊ทœ์น™

ํŒŒ์ผ ์œ ํ˜• ์•ฝ์–ด ์˜ˆ์‹œ
View Controller VC MainVC
Table View Cell TVC OmoolenTVC
Collection View Cell CVC OmoolenCVC

์„œ๋ฒ„ํ†ต์‹ 

  • ์„œ๋น„์Šคํ•จ์ˆ˜๋ช…(postOnboarding) + WithAPI

IBAction

- ๋™์‚ฌ์›ํ˜• + ๋ชฉ์ ์–ด ex) touchBackButton

๋ทฐ ์ „ํ™˜

- pop, push, present, dismiss

- ๋™์‚ฌ + To + ๋ชฉ์ ์ง€ ๋ทฐ (๋‹ค์Œ์— ๋ณด์ผ ๋ทฐ)

- ( dismiss๋Š” dismiss + ํ˜„์žฌ ๋ทฐ )

์• ๋‹ˆ๋ฉ”์ด์…˜

- ๋™์‚ฌ์›ํ˜• + ๋ชฉ์ ์–ด + WithAnimation
- showButtonsWithAnimation

register

- register + ๋ชฉ์ ์–ด
- registerXib

subview๋กœ ๋ถ™์ด๊ธฐ

- attatch

ํ”„๋กœํ† ์ฝœ

- ๋ทฐ ์ด๋ฆ„ + View + Delegate

MARK ์ฃผ์„

// MARK: - Properties**

// MARK: - @IBOutlet Properties**

// MARK: - @IBAction Properties**

// MARK: - View Life Cycle**ย viewDidLoad(), viewWillAppear(_:) โ€ฆ

// MARK: - Extensions**

// MARK: - UITableViewDataSource**

// MARK: - UITableViewDelegate**ย ํ”„๋กœํ† ์ฝœ๋“ค Extension ์œผ๋กœ ๋นผ๊ธฐ

// TODO: -

// FIXME: -

๊ธฐํƒ€๊ทœ์น™

  • self๋Š” ์ตœ๋Œ€ํ•œ ์‚ฌ์šฉ์„ย ์ง€์–‘
  • viewDidLoad()์—์„œ๋Š”ย ํ•จ์ˆ˜ํ˜ธ์ถœ๋งŒ
    • delegate ์ง€์ •, UI๊ด€๋ จ ์„ค์ • ๋“ฑ๋“ฑ ๋ชจ๋‘ ํ•จ์ˆ˜๋กœ
  • ํ•จ์ˆ˜๋Š”ย extension์— ์ •์˜ํ•˜๊ณ  ์ •๋ฆฌ
    • extension์€ ๋ชฉ์ ์— ๋”ฐ๋ผ ๋ถ„๋ฅ˜
    • extension์€ ๊ฐ์ž ํ•„์š”์— ๋”ฐ๋ผ ์‚ฌ์šฉ โ†’ delegate, datasource ๋Š” ๋นผ๋ณด๊ธฐ