Understand locales json


#1

Hi,
i’m trying to localize iOS dialog message like accesso to location… this is my code:

{
“expo”: {
“sdkVersion”: “31.0.0”,

“ios”: {
“infoPlist”: {
“NSLocationWhenInUseUsageDescription”: “Display events near you and help you to reach them”,
},
},
},
“locales”: {
“it”: “./languages/italian.json”,
},
}
}

and this is italian.json

{
“NSLocationWhenInUseUsageDescription”: “Italian text…”
}

locales property is into a correct json position?
The italian.json is corrent? I’ve to add expo, ios or infoPlist parent nodes?

Thanks


#2

Hey @shork,

It should be placed in the expo property.

Cheers,

Adam


#3

I’ve tryed this:

{
“expo”: {
“ios”: {

“infoPlist”: {
“NSLocationWhenInUseUsageDescription”: “English text”,
},
},

“locales”: {
“it”: “./languages/italian.json”,
},
}
}

and the file talian.json is

{
“NSLocationWhenInUseUsageDescription”: “Italian text…”
}

but the result is the same… the dialog text is in english… i’ve to create two separated file with the english text too?

Thanks


#4

Hi Adam,
are there news about this issue?


#5

Just to be sure, are you testing on a standalone via TestFlight? These changes won’t be reflected when testing in the Expo Client.


#6

Yes, standalone iOS app installed by TestFlight