This repository has been archived by the owner on Jun 23, 2024. It is now read-only.
Replies: 1 comment
-
any solution? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
From my understanding, you can set the data-key property to equal a function for custom filtering. This is great except you cant use a predefined function within your component i.e:
const convertDate = (date) => { return moment(date).utc().format("MMM Do YYYY"); }
...
<th data-key={(row) => convertDate(row.date)}>Date</th>
this will throw an exception saying convertDate does not exist. Please assist.
Edit: that being said, you can't reference "moment" directly either (as it will throw an exception saying moment doesn't exist)
Beta Was this translation helpful? Give feedback.
All reactions