在GeometryReader外添加如下语句就可以: .frame(width: geometry.size.width, height: geometry.size.height, alignment: .center)