Localizer package for Asp.Net Core web applications, powered by online translation and auto resource creating.
Say bye-bye to manually creating localization resources...!
IStringLocalizer
, IHtmlLocalizer
, IStringLocalizerFactory
and IHtmlLocalizerFactory
.Install latest preview from nuget :
Install-Package XLocalizer
Add localization settings in startup.cs
:
// Add XLocalizer
services.AddRazorPages()
.AddXLocalizer<LocSource, GoogleTranslateService>(ops =>
{
ops.ResourcesPath = "LocalizationResources";
ops.AutoTranslate = true;
ops.AutoAddKeys = true;
ops.TranslateFromCulture = "en";
});
MIT