Closed Tigrov closed 11 months ago
Introduction of New Method in ViewTrait File A new function called 'getLocale()' has been added to the 'ViewTrait.php' file. This function is designed to provide the locale code, helping to identify the regional setting currently applied.
Addition of New Test in ViewTest File A fresh test named 'testGetLocale()' has been implemented into the 'ViewTest.php' file. This test focuses on evaluating the performance and behavior of the new 'getLocale()' method to ensure it works as expected.
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
38e7351
) 99.74% compared to head (3daa0ff
) 99.74%. Report is 2 commits behind head on master.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
👍
It needs to get current locale when page is rendering
<html lang="<?= Html::encode($view->getLocale()) ?>">
Also this will allow fix issue yiisoft/app#290