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
var _ = require('underscore') | |
var lines = [ | |
"#The test", | |
"###Hello World", | |
"This is a new paragraph.", | |
"It has a second line", | |
"", | |
"This is my new paragraph" | |
]; |
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 ARKit | |
// Example usage: | |
// let twentyCentimeters: Float = 20.cm | |
// let twoMeters: Float = 2.m | |
// let oneMillimeter: Float = 1.mm | |
// let extent: float3 = float3(20.cm, 10.cm, 1.m) | |
extension Int { | |
var mm: Float { |
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 PlaygroundSupport | |
import SwiftUI | |
struct ContentView: View { | |
var jumpAmount: CGFloat { | |
CGFloat(-time * time + time) | |
} | |
var scaleX: CGFloat { 1/scaleY } |
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 | |
final class SizeClassNotifier: ObservableObject { | |
@Published var currentSizeClass: UserInterfaceSizeClass = | |
.compact | |
func updateSizeClass(sizeClass: UserInterfaceSizeClass?) { | |
DispatchQueue.main.asyncAfter(deadline: .now() + 0.3) { | |
self.currentSizeClass = sizeClass ?? .compact |
OlderNewer