Find all available images for as `systemName` in SFSymbols

后端 未结 6 1078
情歌与酒
情歌与酒 2021-01-30 19:38

Where can I find all the system images that are available in the SFSymbols? for example in the SwiftUI Image initializer Image(systemName:)?

I\'

6条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-30 19:51

    Take a look at this Swift Package SFSafeSymbols

    You can access all the SF Symbols from an enum

    static func getRandomSFSymbol() -> SFSymbol {
        return SFSymbol.allCases.randomElement() ?? SFSymbol.xCircle
    }
    

提交回复
热议问题