DataTable: sortOrder
property in DataTableStateEvent always has value of 1
#7092
Labels
Type: Bug
Issue contains a defect related to a specific component.
Describe the bug
The value of
sortOrder
property in DataTableStateEvent is always 1. The expected behavior is the value should vary between 1 | 0 | -1 depending on sort order.Reproducer
https://stackblitz.com/edit/a6xx6a?file=src%2FApp.jsx
System Information
System:
OS: Windows 11 10.0.22631
CPU: (20) x64 13th Gen Intel(R) Core(TM) i7-1370P
Memory: 8.72 GB / 31.66 GB
Binaries:
Node: 21.6.1 - ~\scoop\apps\nvm\current\nodejs\nodejs\node.EXE
npm: 10.2.4 - ~\scoop\apps\nvm\current\nodejs\nodejs\npm.CMD
Browsers:
Edge: Spartan
npmPackages:
primereact: ^10.8.2 => 10.8.2
react: ^18 => 18.2.0
tailwindcss: ^3.4.7 => 3.4.7
Steps to reproduce the behavior
onSort
callback for the data tablesortOrder
property in console (logged from step 3)Expected behavior
The value of
sortOrder
property should alternate 1 | 0 | -1 to indicate asc/desc sort order.The text was updated successfully, but these errors were encountered: