errors and warnings / stdlib / E8115
E8115 error
Locale file is not a JSON object of strings
- area
- stdlib (x8xxx)
- fails the build
- yes
A locale file is not a JSON object whose values are all strings. The file may
not be valid JSON, its top level may not be an object, or a value may be a
number, a table or null. Every translation is a string, so write numbers in
quotes, and fix the JSON syntax if the file doesn't parse.
Example
{ "TITLE": "Kill Tracker", "MAX_KILLS": 100 }import L from "wowlua:locale"print(L.TITLE){ "TITLE": "Kill Tracker", "MAX_KILLS": "100" }import L from "wowlua:locale"print(L.TITLE, L.MAX_KILLS)The compiler reports it like this:
error[E8115]: `MAX_KILLS` in `locales/enUS.json` must be a string = in locales/enUS.json
Related codes
| code | message |
|---|---|
| E8060 | Invalid locale key |
Offline
$ wowlua explain E8115 E8115 (error): Locale file is not a JSON object of strings