This file contains hidden or 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 RxSwift | |
| import RxCocoa | |
| @dynamicMemberLookup | |
| protocol DynamicMemberLookupableObservableType: AssociateObservable { | |
| subscript<T>(dynamicMember keyPath: KeyPath<Value, T>) -> Observable<T> { get } | |
| } | |
| extension DynamicMemberLookupableObservableType { | |
| subscript<T>(dynamicMember keyPath: KeyPath<Value, T>) -> Observable<T> { |
This file contains hidden or 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
| #!/bin/bash | |
| BUILD_DIRECTORY="Build" | |
| function archive_project() { | |
| project_name=$1 | |
| framework_name=$2 | |
| # Archive iOS project. | |
| xcodebuild archive\ |
This file contains hidden or 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
| // | |
| // ViewController.swift | |
| // SampleApp | |
| // | |
| // Created by minsOne on 2022/01/18. | |
| // | |
| import UIKit | |
| import PinLayout | |
| import FlexLayout |
This file contains hidden or 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
| - Supports opening documents in place LSSupportsOpeningDocumentsInPlace | |
| - Application supports iTunes file sharing UIFileSharingEnabled |
This file contains hidden or 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
| alias pip3='pip3 --trusted-host pypi.org --trusted-host files.pythonhosted.org' | |
| alias cXed='rm -rf ~/Library/Saved\ Application\ State/com.apple.dt.Xcode.savedState && xed .' | |
| alias clearXcode='rm -rf ~/Library/Saved\ Application\ State/com.apple.dt.Xcode.savedState' |
This file contains hidden or 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
| tuist graph -t -f dot && sed -E '/(Testing)|(Example)/d' graph.dot > /tmp/tuist_graph.dot | |
| dot -Tpdf /tmp/tuist_graph.dot -o graph.pdf && open graph.pdf | |
| dot -Tpng /tmp/tuist_graph.dot -o graph.png | |
| rm graph.dot |
This file contains hidden or 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 | |
| import DictionaryCoding | |
| /// Note: This relies on the DictionaryCoding package https://github.com/elegantchaos/DictionaryCoding | |
| struct QueryParamEncoder { | |
| func encode<T: Encodable>(_ item: T) throws -> String { | |
| let encoder = DictionaryEncoder() | |
| let encoded: [String: Any] = try encoder.encode(item) | |
| let queryParams = encodeDictionary(encoded) | |
This file contains hidden or 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
| // refer: https://woowabros.github.io/swift/2021/02/18/swift-dynamic-features.html | |
| @dynamicMemberLookup | |
| public struct Builder<Base: AnyObject> { | |
| private var base: Base | |
| public init(_ base: Base) { | |
| self.base = base | |
| } |
This file contains hidden or 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
| alias cXed='rm -rf ~/Library/Saved\ Application\ State/com.apple.dt.Xcode.savedState && xed .' |
This file contains hidden or 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 SwiftUI | |
| struct HalfShape: Shape { | |
| let left: Bool | |
| func path(in rect: CGRect) -> Path { | |
| return Path { path in | |
| let width = rect.width | |
| let height = rect.height |