我使用这个精确的代码,屏幕仍然没有被完全填满。我遗漏了什么?
这是主要的appView:
@main
struct HistoryMarkerApp: App {
@StateObject var firestoreManager = FirestoreManager()
init() {
FirebaseApp.configure()
}
var body: some Scene {
WindowGroup {
ContentView()
}
}
}ContentView:
var body: some View {
VStack(alignment: .leading) {
Text("Hello World")
.font(.title)
Text("Another")
.font(.body)
Spacer()
}
.frame(
minWidth: 0,
maxWidth: .infinity,
minHeight: 0,
maxHeight: .infinity,
alignment: .topLeading
)
.background(Color.red)
}

发布于 2022-03-21 19:43:33
修正:我必须在info.plist (目标信息)文件中重新创建启动屏幕变量。
项目目标->信息:
发射屏
谢谢你帮忙。
https://stackoverflow.com/questions/71562739
复制相似问题