Skip to content

Instantly share code, notes, and snippets.

// Created by Chris Eidhof on 04-01-16.
// Copyright © 2016 Chris Eidhof. All rights reserved.
//
// Large parts copy/pasted from https://github.com/Eonil/TCPIPSocket.Swift
import Foundation
struct TCPIPSocketAddress {
init(_ a:UInt8, _ b:UInt8, _ c:UInt8, _ d:UInt8) {
let a1 = UInt32(a) << 24
enum Command {
case buttonTapped
case textChanged(String)
}
enum SideEffect<C> {
case anEvent(C)
case readFile((String) -> C)
// ...
}
//
// ContentView.swift
// Shared
//
// Created by Chris Eidhof on 05.05.22.
//
import SwiftUI
struct ContentView: View {
//
// ContentView.swift
// NotesClone
//
// Created by Chris Eidhof on 29.06.20.
//
import SwiftUI
@main
import SwiftUI
struct Light: View {
var body: some View {
Circle()
.overlay(rings)
.overlay(
Circle()
.fill(gradient)
.alignmentGuide(VerticalAlignment.center, computeValue: { $0.height/10 })
//
// ContentView.swift
// OverlayTest
//
// Created by Chris Eidhof on 26.09.22.
//
import SwiftUI
struct ContentView: View {
//
// ContentView.swift
// Shared
//
// Created by Chris Eidhof on 16.04.22.
//
import SwiftUI
struct Jump: AnimatableModifier {
final class Loader: BindableObject {
let didChange = PassthroughSubject<Data?, Never>()
var task: URLSessionDataTask!
var data: Data? = nil {
didSet {
didChange.send(data)
}
}
init(_ url: URL) {
//
// ContentView.swift
// TestingMoreSwiftUI
//
// Created by Chris Eidhof on 04.06.19.
// Copyright © 2019 Chris Eidhof. All rights reserved.
//
import SwiftUI
import Combine
//
// ContentView.swift
//
// Created by Chris Eidhof on 20.04.20.
// Copyright © 2020 objc.io. All rights reserved.
//
import SwiftUI
import UIKit