Autocompleted, compile-time constants for Apple's built-in SF Symbols.
A set of over 1,500 consistent, highly configurable symbols you can use in your app. Apple designed SF Symbols to integrate seamlessly with the San Francisco system font, so the symbols automatically ensure optical vertical alignment with text for all weights and sizes. SF Symbols are available in a wide range of weights and scales to help you create adaptable designs.
- See Apple Human Interface Guidelines: https://developer.apple.com/design/human-interface-guidelines/sf-symbols/overview/
- Download the SF Symbols App: https://developer.apple.com/design/downloads/SF-Symbols.dmg
// Directly create UIImages for symbols.
let myIcon = UIImage(symbol: .videoBadgeCircle)
// Configure symbols with `UIImage.SymbolConfiguration` properties.
let bigBoldAlarm = UIImage(symbol: .alarm, weight: .bold, scale: .large)
// All 1500+ symbols are supported.
let icons = [
UIImage(symbol: .star),
UIImage(symbol: .starFill),
UIImage(symbol: .wifi),
UIImage(symbol: .wifiSlash),
UIImage(symbol: .eyedropper),
UIImage(symbol: .tuningfork)
]
// Directly create symbol images.
struct ContentView : View {
var body: some View {
HStack {
Image(symbol: .waveform, symbolScale: .large)
Text("Hello World")
}
}
}
SFSymbols is available through Swift Package Manager as SFSymbols
.
SFSymbols is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'SFSymbols'
SFSymbols is available under the MIT license. See the LICENSE file for more info.