Unplanned
Last Updated: 21 Aug 2023 14:28 by ADMIN
Kyle Smith
Created on: 07 Aug 2023 11:00
Type: Bug Report
4
TypeError: $kendoHtmlEncode is not a function in React Report Viewer when using Vite

I just migrated from building with react-scripts to Vite, as it seems react-scripts is deprecated. After the change, the react report viewer is not functioning correctly. Browser console shows:

Instantiation of Kendo TreeView as Document Map threw an exception TypeError: $kendoHtmlEncode is not a function

Uncaught (in promise) TypeError: $kendoHtmlEncode is not a function

 

2 comments
ADMIN
Dimitar
Posted on: 21 Aug 2023 14:28

Hello,

I suspect that the problem is related to how the viewer's kendo subset is split into chunks by Vite but there is no workaround for that, unfortunately.

Still, while that issue gets fixed, you may use the pure HTML5 Report Viewer in your React applications by following the HTML5 Report Viewer in React Application - Telerik Reporting KB article. No functionality will be lost because the React viewer is a wrapper of the pure viewer so the internal logic is the same.

Hope this will help.

Regards,
Dimitar
Progress Telerik

Stay tuned by visiting our roadmap and feedback portal pages, enjoy a smooth take-off with our Getting Started resources, or visit the free self-paced technical training at https://learn.telerik.com/.
Bharat
Posted on: 17 Aug 2023 04:41

I am also getting the same issue