switch case is ...
Swift โฉ Pattern Matching โฉ Sentence Patterns โฉ
๐ ๆฏ่ผ๏ผ if let ... as?, switch case let ... as
// switch on "protocol type"
switch medium {
case is WebSite: // โญ๏ธ case is (without binding)
default: // ...
}
Last updated
Was this helpful?