xaviersolau/BlazorJsonLocalization

Does not find the translation files net maui preview 10 /net6

whann0205 opened this issue · 2 comments

Since the structure substantiallly changed from net3.1 xamarin i am not sure, where to put
the translation files.
Its directly on the projects root
grafik
grafik
But the lib does not see it...

[0:] SoloX.BlazorJsonLocalization.Services.Impl.EmbeddedJsonLocalizationExtensionService: Warning: Embedded File Locales/Pages/RecentSearches-en.json does not exist

Any idea ? using the latest alpha 1.0.2. alpha 4....

Hello,
Looks like the files are not define as EmbeddedResource.

You should see something like this in your csproj:

<ItemGroup>
    <Content Remove="Locales\Pages\RecentSearches-en.json" />
  </ItemGroup>

  <ItemGroup>
    <EmbeddedResource Include="Locales\Pages\RecentSearches-en.json" />
  </ItemGroup>

Hi,
Yep, that was the problem. I forgot to set the files to embedded and do not copy.
Somehow forgot during the migration...
Perfectly running now on net maui / net6!!