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
// | |
// GraphQL.swift | |
// | |
// Created by Cenk Bilgen on 2018-10-15. | |
// Copyright © 2018 Cenk Bilgen. All rights reserved. | |
// | |
import Foundation | |
// Generate a simple GraphQL search based query |
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
// | |
// URLRequestExtension.swift | |
// | |
// Created by Cenk Bilgen on 2019-01-30. | |
// Copyright © 2019 abc. All rights reserved. | |
// | |
import Foundation | |
extension URLRequest { |
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
// | |
// OriginAxis.swift | |
// | |
// Created by abc on 2019-03-07. | |
// Copyright © 2019 Cenk Bilgen. All rights reserved. | |
// | |
import Foundation | |
import SceneKit |
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
// | |
// EnvironmentVariables.swift | |
// PlaylogR | |
// | |
// Created by Cenk Bilgen on 2019-10-12. | |
// Copyright © 2019 Cenk Bilgen. All rights reserved. | |
// | |
import SwiftUI | |
import UIKit |
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
//------------------------------------------------------------------------ | |
// The SwiftUI Lab: Advanced SwiftUI Animations | |
// https://swiftui-lab.com/swiftui-animations-part1 (Animating Paths) | |
// https://swiftui-lab.com/swiftui-animations-part2 (GeometryEffect) | |
// https://swiftui-lab.com/swiftui-animations-part3 (AnimatableModifier) | |
//------------------------------------------------------------------------ | |
import SwiftUI | |
struct ContentView: View { | |
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 | |
import Combine | |
var count = 0 | |
enum Marker: CustomDebugStringConvertible { | |
case A(Int) | |
case B(Int) | |
var debugDescription: String { |
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 | |
import Combine | |
fileprivate class CancellableStore { | |
static let shared = CancellableStore() | |
var cancellables = Set<AnyCancellable>() | |
} | |
public enum DownloadOutput { | |
case complete(Data) |
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 SwiftUI | |
import Combine | |
#if os(iOS) | |
import UIKit.UIResponder | |
#endif | |
class KeyboardObserver: ObservableObject { | |
struct State: Equatable { | |
let frame: CGRect | |
let isLocal: Bool // on multitasking iPad apps, all visible apps notified |
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
// Using `.updating(...)` with a @GestureState seemed like the way to go | |
// but pressing state end update is not readily available | |
// standard `.onLongPress` modifier works best | |
struct LongPressExample: View { | |
let duration: TimeInterval | |
@State private var progress: CGFloat = 0 | |
@State private var isDone = false | |
var body: some View { |