- Create a new
InfoPlist.stringsfile - Add the following line to that file:
UILaunchStoryboardName = "LaunchScreen";
| #!/bin/bash | |
| # Defaults | |
| PLATFORM="iOS Simulator" | |
| DEVICE="iPhone 16 Pro Max" | |
| OS="latest" | |
| # Required | |
| APP="" | |
| BUNDLE_ID="" |
| #! /bin/bash | |
| # Check if an argument is provided | |
| if [ $# -eq 0 ]; then | |
| echo "Error: Please provide a prompt as an argument." | |
| echo "Usage: $0 <prompt>" | |
| exit 1 | |
| fi | |
| echo "Prompt: $1" |
| struct Message: Codable, Identifiable { | |
| var id: String | |
| var role: Role | |
| var content: String? | |
| var toolCalls: [ToolCall]? | |
| var finishReason: FinishReason? | |
| var created: Date | |
| var modified: Date | |
| enum Role: String, Codable { |
| import Foundation | |
| import OpenAI | |
| func JSONSchemaEncoder<T>(_ instance: T) -> JSONSchema { | |
| var properties = [String: JSONSchema.Property]() | |
| var required = [String]() | |
| let mirror = Mirror(reflecting: instance) | |
| for child in mirror.children { | |
| if let label = child.label, let schemaInfo = child.value as? any SchemaProtocol { |
The following code results in a view that does what you expect, always shows the content appearing at the bottom of the scroll view. However, if you start with an empty view and populate it with a few buttons, the tap targets for those buttons will be off until you manually scroll the view.
ScrollView {
LazyVStack {
Button(action: {}) { Text("Foo") }
...
}
}| *** Cluster Setup for Google Container Engine *** | |
| 0/ Install and configure local gcloud and kubectl: https://cloud.google.com/sdk/docs/ | |
| > gcloud components install kubectl | |
| 1/ Configure Google Cloud account: | |
| > gcloud config set account YOUR_EMAIL_ADDRESS | |
| > gcloud config set project YOUR_PROJECT_ID | |
| > gcloud config set compute/zone us-west1-a | |
| > gcloud config set container/cluster example |
| import UIKit | |
| import SwiftUI | |
| import PlaygroundSupport | |
| // CustomParentView is a custom UIKit view. Its Coordinator can be used | |
| // to manage delegates if needed (e.g. UIContextMenuInteractionDelegate). | |
| struct CustomParentView<Content: View>: UIViewRepresentable { | |
| let content: UIView | |
| import SwiftUI | |
| import PanModal | |
| struct ExampleView: View { | |
| @State var detail: AnyView? = nil | |
| @State var items: [String] = ["Detail 1", "Detail 2", "Detail 3"] | |
| var body: some View { | |
| NavigationView { |