๐ธchild view
SwiftUI โฉ view โฉ hierarchy โฉ child view
child view (ๅญ่ฆๅ)
่ขซ container view ๆๅ ๅซ็ view๏ผไพๅฆ๏ผ
ContainerView {
childView
}
ใ่ขซ view modifier ไฟฎ้ฃพ็ view๏ผไพๅฆ๏ผ
childView
.modifier()
ไธญ็childView
ใ
root view ่ๅ ถๆๅซ็ๆๆๅญ่ฆๅ (descendants) ๅฝขๆ view hierarchyใ
่จป๏ผๅจ UIKit
ไธญ้ๅธธ็จฑ็บ subviewใ
ๅจ container view ็็ๆณ๏ผๅคงๆฌ่่ฃก้ข็ views ๅฐฑๆฏ child viewsใ
ๅจๆ view modifiers ็ๆ ๆณไธ๏ผ่ฆๅ้ไพ็๏ผๅ้ข็ๆฏ child view๏ผๅพ้ข็ๆฏ parent viewใ
ๅฆๆ็ตๅ่ตทไพ็๏ผ
้ๆ็ view hierarchy ๅฐฑๆ่ฎๆ๏ผ
Last updated