Localization of the React Report Viewer
The article elaborates on how to localize the messages displayed by the React Report Viewer.
-
To localize the report viewer, create a new TypeScript file
stringResources.ts
:The file can contain all or only a part of the string resources which would be localized. For a full list of the report viewer string resources which could be localized, please refer to HTML5 Report Viewer Localization.
-
Import the new file in the component where the viewer is used:
-
Use the useEffect hook to extend the viewer object with the string resources for the desired culture after the component has mounted: