This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// BaseView.swift | |
// | |
// Created by Aaron Lee on 2022/03/10. | |
// | |
import SnapKit | |
import Then | |
import UIKit | |
class BaseView: UIView { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// BaseTableViewCell.swift | |
// | |
// Created by Aaron Lee on 2022/03/10. | |
// | |
import SnapKit | |
import Then | |
import UIKit | |
class BaseTableViewCell: UITableViewCell { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// BaseViewController.swift | |
// | |
// Created by Aaron Lee on 2022/03/10. | |
// | |
import RxCocoa | |
import RxGesture | |
import RxSwift | |
import SnapKit | |
import Then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import RxCocoa | |
import RxSwift | |
import SocketIO | |
final class MySocketManager { | |
struct Relays { | |
// Custom events: | |
/// User properties updated |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Alamofire | |
import Foundation | |
import RxSwift | |
/// APIService | |
protocol APIService { | |
func request<T: BaseAPIResponse>(with request: URLRequest) -> Observable<APIResult<T>> | |
func upload<T: BaseAPIResponse>(with url: URL, | |
method: Alamofire.HTTPMethod, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
class AsyncOperation: Operation { | |
enum State: String { | |
case ready, executing, finished | |
fileprivate var keyPath: String { | |
return "is\(rawValue.capitalized)" | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// UIApplication+Ext.swift | |
// BottomSheetExample | |
// | |
// Created by Aaron Lee on 2021/11/06. | |
// | |
import UIKit | |
extension UIApplication { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
let array = [0, 1, 2, 3, 4, 5, 6, 7, 8] | |
let selectedIndexes = [0, 1, 3, 5, 7] | |
extension Array { | |
subscript (safe index: Int) -> Element? { | |
return indices ~= index ? self[index] : nil | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# .git/hooks/prepare-commit-msg | |
if [ -z "$BRANCHES_TO_SKIP" ]; then | |
BRANCHES_TO_SKIP=(master develop release hotfix) | |
fi | |
PROJECT_ID=RPL | |
BRANCH_NAME=$(git symbolic-ref --short HEAD) | |
BRANCH_NAME="${BRANCH_NAME##*/}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import UIKit | |
struct Resolution { | |
let width: CGFloat | |
let height: CGFloat | |
} | |
let resolution1 = Resolution(width: 1_920, height: 1_080) | |
let resolution2 = Resolution(width: 1_080, height: 1_920) |
NewerOlder