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 | |
struct ContentView: View { | |
let itemHeight: CGFloat = 50 | |
var body: some View { | |
GeometryReader { geo in | |
ScrollView { | |
VStack { | |
Text("Start") |
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
@dynamicMemberLookup | |
struct Configurator<T> { | |
var configure: (inout T) -> Void = { _ in } | |
subscript<V>(dynamicMember keyPath: WritableKeyPath<T, V>) -> Builder<V> { | |
.init(configure: configure, keyPath: keyPath) | |
} | |
static subscript<V>(dynamicMember keyPath: WritableKeyPath<T, V>) -> Builder<V> { | |
.init(configure: { _ in }, keyPath: keyPath) |
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
class A { | |
var b: B? | |
deinit { | |
print("A being deallocated") | |
} | |
} | |
class B { | |
var a: A? | |
deinit { |
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
#!/bin/bash | |
repo="HandmadeHero" | |
source="source" | |
if [ ! -d "$repo" ] | |
then | |
git init "$repo" | |
fi |
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/UIKit.h> | |
#import <SceneKit/SceneKit.h> | |
#import <OpenGLES/ES2/gl.h> | |
#import <OpenGLES/ES2/glext.h> | |
@interface View : UIView | |
@property (strong, nonatomic) SCNScene *scene; | |
- (void)renderFrame; |
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/Foundation.h> | |
@interface QueueProxy : NSProxy | |
+ (id) proxyForDelegate: (id)delegate onQueue: (NSOperationQueue *)queue; | |
@end |