In my project I use Syncfusion.Blazor and also original Bootstrap 5.2 (https://getbootstrap.com/docs/5.2/getting-started/download/).
I've noticed that when I use SfAccumulationChart control, there is a conflict with Bootstrap js file.
I've uploaded a sample project to reproduce the issue:
- Open project in VS and run it
- On the Index page you see syncfusion chart. Now please restore the window or open Developer Console (basically you need to change a size of the web browser)
- Chart should gone now. When you open Developer Console you will see this error:
blazor.server.js:1 Uncaught (in promise) TypeError: Converting circular structure to JSON
--> starting at object with constructor 'Window'
--- property 'window' closes the circle
at JSON.stringify (<anonymous>)
at D (blazor.server.js:1:5362)
at w (blazor.server.js:1:2155)
at C.invokeMethodAsync (blazor.server.js:1:4014)
at syncfusion-blazor.min.js:9:7565
I've discovered that the problem is Bootstrap js file added to the _Layout.cshtml file:
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-kenU1KFdBIe4zVF0s0G1M5b4hcpxyD9F7jL+jjXkk+Q2h455rYXK/7HAuoJl+0I4" crossorigin="anonymous"></script>
If I remove it, there is no this problem anymore
Bootstrap 5 is used by many web applications so probably Syncfusion shouldn't conflict with it
If you need more info, please let me know
Attachment:
BlazorApp4_3722c4d0.zip