- Create 10GB FreeBSD image using QEMU.
- Run the VM using xhyve.
- Mount host directory.
- Resize the image.
- OSX
- Homebrew
import SwiftUI | |
/// Supplies an observable object to a view’s hierarchy. | |
/// | |
/// The purpose of `WithBindable` is to make it possible to instantiate | |
/// observable objects from environment values, while keeping the object | |
/// alive as long as the view is rendered. | |
/// | |
/// For example: | |
/// |
@propertyWrapper | |
struct Proxy<EnclosingType, Value> { | |
typealias ValueKeyPath = ReferenceWritableKeyPath<EnclosingType, Value> | |
typealias SelfKeyPath = ReferenceWritableKeyPath<EnclosingType, Self> | |
static subscript( | |
_enclosingInstance instance: EnclosingType, | |
wrapped wrappedKeyPath: ValueKeyPath, | |
storage storageKeyPath: SelfKeyPath | |
) -> Value { |
import SwiftUI | |
struct MyValue: _ViewTraitKey { | |
static var defaultValue: Int = 0 | |
} | |
extension View { | |
func myValue(_ value: Int) -> some View { | |
_trait(MyValue.self, value) | |
} |