Use GridPDFExport with react Link

0 Answers 66 Views
Grid PDF Processing
Thulani
Top achievements
Rank 1
Thulani asked on 30 Jun 2022, 10:30 AM

I have a scenario to export a Grid to pdf using the GridPDFExport. What I am observing is that this fails when using the react Link with the error 

Error: Invariant failed: You should not use <Link> outside a <Router>

What I notice is that this works well with an anchor but this is something I cannot use in my situation as it caused full page reloads on the web page itself. How can I handle this?

 

Thanks

Konstantin Dikov
Telerik team
commented on 04 Jul 2022, 05:48 AM

Hi Thulani,

We already have logged issue for this problem, which is due to the fact that the GridPDFExport while exporting will render only the content wrapped within the component and since the Router is outside of it, the error will occur. You can follow the progress of the issue in the link below:

Meanwhile, you can use the PDFExport instead as shown in the following example:

No answers yet. Maybe you can help?

Tags
Grid PDF Processing
Asked by
Thulani
Top achievements
Rank 1
Share this question
or