Created
July 22, 2021 04:49
-
-
Save tifoaudii/86eb551f4f160acb4bc7f0647cb0aa16 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension UITextView: MutableLocalizable { | |
func translate(to language: Language) { | |
switch language { | |
case .indonesia: | |
text = "Tolong" | |
case .thailand: | |
text = "..." | |
case .vietnam: | |
text = "..." | |
} | |
} | |
static var languages: [Language] { | |
[.indonesia, .thailand] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment