These are general convention guidelines for the library style.
Please check out the Example
module for a better understanding.
Object | Prefix | Example |
---|---|---|
UIButton |
btn | eq. btnStart |
UICollectionView |
cv | eq. cvPhotos |
UIControl |
ctrl | eq. ctrlRefresh |
UIImageView |
iv | eq. ivPhoto |
UILabel |
lbl | eq. lblTitle |
UIScrollView |
sv | eq. svAbout |
UISwitch |
sw | eq. swMute |
UITableView |
tbl | eq. tblNames |
UITextField |
txt | eq. txtEmail |
UITextView |
tv | eq. tvSummary |
UIView |
view | eq. viewBox |
UIViewController |
vc | eq. vcHome |
Object | Prefix | Example |
---|---|---|
Array |
lst | eq. lstItems |
Dictionary |
dict | eq. dictOptions |
String |
str | eq. strName |
UIColor |
clr | eq. clrWhite |
UIImage |
img | eq. imgPhoto |
Object | Example |
---|---|
CommonCollectionViewHandler |
eq. PhotoCollectionViewHandler |
CommonCollectionViewListener |
eq. PhotoCollectionViewListener |
CommonModel |
eq. ProfileModel |
CommonTableViewHandler |
eq. FriendTableViewHandler |
CommonTableViewListener |
eq. FriendTableViewListener |
CommonView |
eq. ProfileView |
CommonViewController |
eq. ProfileViewController |
CommonViewModel |
eq. ProfileViewController |
Object | Prefix | Example |
---|---|---|
Selector |
do | eq. doLoadView, doTapStart |
PassthroughSubject |
event | eq. eventLoadView, eventTapStart |
AnyCancellable |
handle | eq. handleLoadView, handleTapStart |
XCTest |
test | eq. testLoadView, testTapStart |
build(_ superview: UIView)
build
bind
handleLoadSomeViewName
handleTapSomeButtonName
doLoadSomeViewName
doTapSomeButtonName