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 UIKit | |
import RealmSwift | |
class Data: Object { | |
dynamic var name = "" | |
... | |
dynamic var order = 0 // 並べ替えのためのカラムが必要 | |
} |
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 UIKit | |
import RealmSwift | |
class Data: Object { | |
dynamic var name = "" | |
... | |
} | |
class DataWrapper: Object { | |
let list = List<Data>() |
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
// | |
// PaginationNetworkLogic.swift | |
// | |
// Created by Daniel Tartaglia on 4/9/17. | |
// Copyright © 2019 Daniel Tartaglia. MIT License | |
// | |
import RxSwift | |
struct PaginationUISource { |
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
1. Create a new xcode project | |
- You can skip this if you're adding the playground to an existing project | |
2. File > Save as workspace - save workspace in project folder | |
- You can skip this if you're adding the playground to an existing workspace | |
3. File > Playground - create new playground in project folder | |
4. Drag playground in at the _workspace_ level (root item, i.e. _not_ under the project) | |
5. Add a new Framework to your project (I usually name mine something like 'PlaygroundKit') | |
- You don't need to include tests | |
- Choose 'None' for Enbed in Application | |
6. Make all project files you want to be accessible to the playground are members of the new target |
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 RxCocoa | |
import RxSwift | |
public extension Reactive where Base: UISearchController { | |
var delegate: DelegateProxy<UISearchController, UISearchResultsUpdating> { | |
return RxSearchResultsUpdatingProxy.proxy(for: base) | |
} | |
var searchPhrase: Observable<String> { |
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 | |
let dateFormatter = DateFormatter() | |
struct NoteItem: Codable, Hashable, Identifiable { | |
let id: Int | |
let text: String | |
var date = Date() | |
var dateText: String { | |
dateFormatter.dateFormat = "MMM d yyyy, h:mm a" |
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
// | |
// RxDataSources+SkeletonView.swift | |
// | |
// Created by mack on 4/7/20. | |
// | |
import Foundation | |
import UIKit | |
import RxSwift | |
import RxDataSources |