Skip to content

Latest commit

 

History

History
21 lines (16 loc) · 418 Bytes

README.md

File metadata and controls

21 lines (16 loc) · 418 Bytes

Usage

Prefix any string with ^ to make it case insensitive. Comparison with other strings will use Swift's localizedCaseInsensitiveCompare function under the hood:

let fileExtension = "JPG"

let message: String

switch ^fileExtension {
case "jpg":
    message = "It's a jpg!"
default:
    message = "It's not a jpg!"
}