-
-
Notifications
You must be signed in to change notification settings - Fork 252
Description
Describe the bug
when grid is used inside of form tag (aspx page, asp.net, form required) it will trigger postback because button type is not specified
and default is type=submit.
To Reproduce
have grid container inside of the form tags and use client side grid with local array as data source but with pagination (no server side calls) and click next.
Expected behavior
grid loads next page, it works fine but immideately after that a form submit occures and entire page is reloaded.
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
- OS: Windows 10 Pro
- Browser: Microsoft Edge
- Version: 108.0.1462.42 (Official build) (64-bit)
Additional context
this will fix the issue if called after grid is rendered.
code:
document.getElementById("divLog").querySelectorAll('[role="button"]').forEach(function (el) {
el.setAttribute("type", "button");
});