How do you handle a mixture of string/number columns with global filter? #4163
Replies: 4 comments 6 replies
-
is still no update about this? |
Beta Was this translation helpful? Give feedback.
-
Similar problem; mixture of primitives and nodes in the same column. I suspect the answer is to provide customer filters per column definition. |
Beta Was this translation helpful? Give feedback.
-
I approached it in one of two ways.
Here
Obviously the above function can be whatever you like depending on your data and filtering rules. |
Beta Was this translation helpful? Give feedback.
-
FYI This issue was fixed in https://github.com/TanStack/table/releases/tag/v8.5.26 |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
EDIT: Was poking at this for a few more moments and realized that it's providing that error on columns that contain numbers, but if all numerical columns are set to
enableGlobalFilter: false
then it's OK. So let me rephrase my question - How would I specify and handle a numerical column for global filters? 😄====
Hi - upgrading from v7 to v8 and keep running into
TypeError: l.toLowerCase is not a function
for my global filter. I've followed the example for global filtering and read through the docs but can't seem to pinpoint what's causing it. Seems that if I add onenableGlobalFilter: false
for certain columns it fixes it, but I'm not connecting the dots on why those columns are an issue as it's using anaccessoryKey
on a value that is a string or number and not an object/array/etc.I've scoured the docs and googled around on the issue but can't seem to find anything related, any advice would be handy.
This is the type def for the data, an array of inventory objects
And my column def
Any advice would be lovely 🙏
Beta Was this translation helpful? Give feedback.
All reactions