Name | Department name | Department company name | Birth date | Age |
|---|---|---|---|---|
| Dustin Sawayn | Industrial | Runolfsdottir - Cummerata | May 20 1980 | 43 |
| Earnest Heller | Health | Johnston LLC | Nov 26 1991 | 32 |
| Sheila Kessler | Automotive | Sipes Inc | Apr 12 1982 | 41 |
| Brayan Macejkovic | Baby | Johnston LLC | Jun 30 1946 | 77 |
| Assunta Ankunding | Books | Crist and Sons | May 26 1978 | 45 |
| Javonte Schumm | Clothing | Runolfsdottir - Cummerata | Mar 04 1956 | 67 |
| Jennifer Von | Shoes | Welch - Tremblay | Feb 22 1985 | 38 |
| Mozell Becker | Grocery | Jakubowski - Rolfson | Sep 20 1974 | 49 |
| Horace Bayer | Home | Jakubowski - Rolfson | Jul 04 1996 | 27 |
| Chauncey Hoeger | Clothing | Johnston LLC | Apr 08 1982 | 41 |
| Remington Hansen | Outdoors | Nicolas Group | Apr 17 1967 | 56 |
| Sammy Mayer | Outdoors | Crist and Sons | Jul 12 1972 | 51 |
| Marilou Morar | Shoes | Runolfsdottir - Cummerata | Jul 30 1974 | 49 |
| Armando Zieme | Automotive | Jakubowski - Rolfson | Oct 08 1976 | 47 |
| Dakota Little | Movies | Crist and Sons | Sep 01 1977 | 46 |
| Tyson Howell | Tools | Kub and Sons | Jan 02 1992 | 32 |
| Bartholome Gibson | Outdoors | Crist and Sons | Dec 26 2005 | 18 |
| Leta Corwin | Garden | Nicolas Group | Dec 02 1983 | 40 |
| Geovany Koelpin | Movies | Runolfsdottir - Cummerata | Sep 27 1979 | 44 |
| Celine Feest | Games | Sipes Inc | Feb 18 1968 | 55 |
| Alanna Bashirian | Garden | Sipes Inc | Jun 15 2005 | 18 |
| Eldred Grant | Outdoors | Jakubowski - Rolfson | Mar 11 1971 | 52 |
| Freddy Gottlieb | Clothing | Crist and Sons | Jan 19 1951 | 72 |
| Immanuel Wolff | Outdoors | Sipes Inc | Mar 08 1959 | 64 |
| Devante Jakubowski | Garden | Sipes Inc | Jun 30 1961 | 62 |
| Ilene Green | Toys | Runolfsdottir - Cummerata | Apr 20 1961 | 62 |
| Estevan Ryan | Shoes | Johnston LLC | May 21 1951 | 72 |
| Jeffry Roberts | Shoes | Johnston LLC | Nov 11 1972 | 51 |
| Etha Kerluke | Baby | Runolfsdottir - Cummerata | Jul 25 1967 | 56 |
| Hans Baumbach | Kids | Welch - Tremblay | Apr 29 1970 | 53 |
| Felipe Kuhlman | Tools | Nicolas Group | Apr 01 1973 | 50 |
| Alfred Jacobs | Outdoors | Runolfsdottir - Cummerata | Sep 10 1964 | 59 |
| Viva Schmitt | Garden | Sipes Inc | Sep 20 1972 | 51 |
| Emiliano Kessler | Toys | Nicolas Group | May 30 2001 | 22 |
| Reymundo Parisian | Home | Johnston LLC | May 11 1948 | 75 |
| Carlee Wehner | Shoes | Runolfsdottir - Cummerata | Oct 06 1972 | 51 |
| Victor Kiehn | Industrial | Johnston LLC | Jul 02 1977 | 46 |
| Trenton Cronin | Music | Jakubowski - Rolfson | Sep 22 1996 | 27 |
| Jackeline Mueller | Home | Johnston LLC | Apr 17 1984 | 39 |
| Mason Reynolds | Garden | Sipes Inc | Sep 10 1950 | 73 |
| Myles Schamberger | Sports | Johnston LLC | Nov 04 1984 | 39 |
| John Murazik | Music | Johnston LLC | May 14 1988 | 35 |
| Gerald Terry | Industrial | Sipes Inc | Mar 09 1994 | 29 |
| Hazel Trantow | Music | Johnston LLC | Jun 23 1952 | 71 |
| Litzy Harris | Music | Welch - Tremblay | Aug 15 1985 | 38 |
| Leonie Strosin | Automotive | Sipes Inc | Sep 19 1948 | 75 |
| Ila Runolfsdottir | Automotive | Schmidt and Sons | Jul 23 2000 | 23 |
| Destiny Jacobson | Sports | Johnston LLC | Apr 13 1958 | 65 |
| Christop Tillman | Tools | Welch - Tremblay | May 08 1990 | 33 |
| Curtis Parker | Automotive | Runolfsdottir - Cummerata | Mar 11 1945 | 78 |
| Otto Boehm | Shoes | Runolfsdottir - Cummerata | Jan 30 2001 | 22 |
| Geoffrey Pacocha | Baby | Johnston LLC | Feb 25 1945 | 78 |
| Reinhold Rosenbaum | Jewelery | Johnston LLC | Feb 08 1986 | 37 |
| Adan O'Conner | Electronics | Schmidt and Sons | Dec 14 1975 | 48 |
| Kelley Keebler | Outdoors | Runolfsdottir - Cummerata | Aug 27 1971 | 52 |
| Genoveva Nikolaus | Beauty | Crist and Sons | Dec 06 1963 | 60 |
| Ana Braun | Books | Crist and Sons | Jun 08 2000 | 23 |
| Mark Pfannerstill | Health | Mueller, Hodkiewicz and Beahan | Feb 01 1967 | 56 |
| Esperanza Thompson | Kids | Runolfsdottir - Cummerata | Jun 29 1985 | 38 |
| Maribel Kuvalis | Baby | Mueller, Hodkiewicz and Beahan | Dec 01 1962 | 61 |
| Dorothy Anderson | Outdoors | Jakubowski - Rolfson | Oct 12 1999 | 24 |
| Jayne Stiedemann | Games | Kub and Sons | Jun 10 1969 | 54 |
| Thalia Crona | Computers | Mueller, Hodkiewicz and Beahan | Nov 30 1990 | 33 |
| Maude VonRueden | Clothing | Jakubowski - Rolfson | Apr 19 1963 | 60 |
| Ellie Franey | Industrial | Runolfsdottir - Cummerata | Mar 02 1993 | 30 |
| Karley Hauck | Sports | Johnston LLC | Apr 11 1947 | 76 |
| Amiya Lowe | Beauty | Mueller, Hodkiewicz and Beahan | Apr 23 1946 | 77 |
| Nicola Adams | Grocery | Crist and Sons | Apr 19 1951 | 72 |
| Darrin Moore | Automotive | Crist and Sons | Dec 30 2003 | 20 |
| Braden Heathcote | Toys | Crist and Sons | Mar 01 1951 | 72 |
| Glennie Bailey | Outdoors | Crist and Sons | Apr 20 1981 | 42 |
| Agustina Ruecker | Shoes | Kub and Sons | May 30 1957 | 66 |
| Sim Thiel | Beauty | Sipes Inc | Jun 12 1972 | 51 |
| Valentin Franey | Books | Crist and Sons | Apr 21 1945 | 78 |
| Mable Kautzer | Music | Jakubowski - Rolfson | Nov 25 1982 | 41 |
| Torrance Halvorson | Outdoors | Sipes Inc | Jul 10 1981 | 42 |
| Erica Bogan | Electronics | Johnston LLC | Mar 22 2000 | 23 |
| Addison Sauer | Garden | Crist and Sons | Apr 06 1988 | 35 |
| Curtis Rohan | Baby | Sipes Inc | Jan 10 1995 | 29 |
| Caterina Hodkiewicz | Movies | Runolfsdottir - Cummerata | Aug 16 1952 | 71 |
| Jarrett Glover | Health | Mueller, Hodkiewicz and Beahan | May 12 1949 | 74 |
| Jamar Lemke | Health | Jakubowski - Rolfson | Jan 14 1952 | 72 |
| Winona O'Keefe | Jewelery | Schmidt and Sons | Mar 17 1975 | 48 |
| Candelario Kris | Kids | Schmidt and Sons | Nov 30 1954 | 69 |
| Maria Casper | Clothing | Schmidt and Sons | Aug 23 1978 | 45 |
| Shaylee Larkin | Books | Welch - Tremblay | Oct 13 1979 | 44 |
| Genevieve Cartwright | Garden | Nicolas Group | Jul 14 1958 | 65 |
| Curtis McLaughlin | Sports | Crist and Sons | Aug 03 1946 | 77 |
| Ulises Fay | Garden | Sipes Inc | Nov 13 1950 | 73 |
| Ivah Weissnat | Home | Mueller, Hodkiewicz and Beahan | Oct 30 1960 | 63 |
| Darrin Cartwright | Movies | Nicolas Group | Nov 25 1989 | 34 |
| Wiley McClure | Outdoors | Jakubowski - Rolfson | Jun 03 1960 | 63 |
| Lou Cummings | Kids | Schmidt and Sons | Nov 11 1996 | 27 |
| Johnathon Leuschke | Grocery | Jakubowski - Rolfson | Apr 05 1949 | 74 |
| Carleton Witting | Garden | Sipes Inc | Feb 06 1955 | 68 |
| Brycen Bergnaum | Garden | Nicolas Group | Sep 22 1960 | 63 |
| Lyric Lindgren | Grocery | Jakubowski - Rolfson | Apr 29 1979 | 44 |
| Corrine Kassulke | Tools | Jakubowski - Rolfson | Dec 15 1994 | 29 |
| Johanna Dietrich | Grocery | Mueller, Hodkiewicz and Beahan | Aug 15 1969 | 54 |
| Georgianna Bruen | Grocery | Sipes Inc | May 05 1955 | 68 |
records you’re feeding to Mantine DataTable based on your own logic in order to perform searching and filtering.import { Box, Button, MultiSelect, Stack, TextInput } from '@mantine/core';import { DatePicker, type DatesRangeValue } from '@mantine/dates';import { useDebouncedValue } from '@mantine/hooks';import { IconSearch } from '@tabler/icons-react';import dayjs from 'dayjs';import { DataTable } from 'mantine-datatable';import { useEffect, useMemo, useState } from 'react';import { employees } from '~/data';const initialRecords = employees.slice(0, 100);export default function SearchingAndFilteringExample() {const [records, setRecords] = useState(initialRecords);const departments = useMemo(() => {const departments = new Set(employees.map((e) => e.department.name));return [...departments];}, []);const [query, setQuery] = useState('');const [selectedDepartments, setSelectedDepartments] = useState<string[]>([]);const [birthdaySearchRange, setBirthdaySearchRange] = useState<DatesRangeValue>();const [debouncedQuery] = useDebouncedValue(query, 200);useEffect(() => {setRecords(initialRecords.filter(({ firstName, lastName, department, birthDate }) => {if (debouncedQuery !== '' &&!`${firstName} ${lastName}`.toLowerCase().includes(debouncedQuery.trim().toLowerCase())) {return false;}if (birthdaySearchRange &&birthdaySearchRange[0] &&birthdaySearchRange[1] &&(dayjs(birthdaySearchRange[0]).isAfter(birthDate, 'day') ||dayjs(birthdaySearchRange[1]).isBefore(birthDate, 'day'))) {return false;}if (selectedDepartments.length && !selectedDepartments.some((d) => d === department.name)) {return false;}return true;}));}, [debouncedQuery, birthdaySearchRange, selectedDepartments]);return (<Box sx={{ height: 300 }}><DataTablewithBorderrecords={records}columns={[{accessor: 'name',render: ({ firstName, lastName }) => `${firstName} ${lastName}`,filter: (<TextInputlabel="Employees"description="Show employees whose names include the specified text"placeholder="Search employees..."icon={<IconSearch size={16} />}value={query}onChange={(e) => setQuery(e.currentTarget.value)}/>),filtering: query !== '',},{accessor: 'department.name',filter: (<MultiSelectlabel="Departments "description="Show all employees working at the selected departments"data={departments}value={selectedDepartments}placeholder="Search departments…"onChange={setSelectedDepartments}icon={<IconSearch size={16} />}clearablesearchable/>),filtering: selectedDepartments.length > 0,},{ accessor: 'department.company.name' },{accessor: 'birthDate',render: ({ birthDate }) => dayjs(birthDate).format('MMM DD YYYY'),filter: ({ close }) => (<Stack><DatePickermaxDate={new Date()}type="range"value={birthdaySearchRange}onChange={setBirthdaySearchRange}/><Buttondisabled={!birthdaySearchRange}color="red"onClick={() => {setBirthdaySearchRange(undefined);close();}}>Reset</Button></Stack>),filtering: Boolean(birthdaySearchRange),},{ accessor: 'age', render: ({ birthDate }) => dayjs().diff(birthDate, 'y') },]}/></Box>);}
Mantine DataTable to accommodate every possible usage scenario out there. Most of the times you’d have to deal with pagination, sorting, asynchronous loading; sometimes you’d have to place a search box or custom filtering criteria selectors in the header of your entire website/application.





