recruit-lifestyle / L.swift

[DEPRECATED] L.Swift is deprecated. you can use R.swift instead
MIT License
12 stars 2 forks source link

L.swift should generate a function which returns NSLocalizedString #1

Closed 3ign0n closed 9 years ago

3ign0n commented 9 years ago

Currently, we have to call NSLocalizedString function to access every localized string resource.

    label?.text = NSLocalizedString(L.foo.bar.message, comment: "")

But it will become much easier to access localizable.strings, if L.swift generate a function or a computed property returning localized string. Like this:

    label?.text = L.foo.bar.message.localizedString()

    // Is this much better?
    label?.text = L.foo.bar.message.localizedString

Thanks in advance :)