---
title: slash
framework: swiftui
role: symbol
role_heading: Type Property
path: swiftui/symbolvariants/slash-swift.type.property
---

# slash

A variant that draws a slash through the symbol.

## Declaration

```swift
static let slash: SymbolVariants
```

## Discussion

Discussion Use this variant with a call to the symbolVariant(_:) modifier to draw symbols with a slash, for those symbols that have such a variant: VStack(spacing: 20) {     HStack(spacing: 20) {         Image(systemName: "flag")         Image(systemName: "heart")         Image(systemName: "bolt")         Image(systemName: "star")     }     HStack(spacing: 20) {         Image(systemName: "flag")         Image(systemName: "heart")         Image(systemName: "bolt")         Image(systemName: "star")     }     .symbolVariant(.slash) }

## See Also

### Getting symbol variants

- [none](swiftui/symbolvariants/none.md)
- [circle](swiftui/symbolvariants/circle-swift.type.property.md)
- [square](swiftui/symbolvariants/square-swift.type.property.md)
- [rectangle](swiftui/symbolvariants/rectangle-swift.type.property.md)
- [fill](swiftui/symbolvariants/fill-swift.type.property.md)
