Regular Table
Basic Table

The "Basic Table" component provides a straightforward way to create structured tables in your web applications. This table style is clean and minimal, making it suitable for a wide range of use cases.

Example code / preview
# First Name Last Name Username
1 Angelina Jolie @angelinajolie
2 Brad Pitt @bradpitt
3 Charlie Hunnam @charliehunnam
# First Name Last Name Username
1 Angelina Jolie @angelinajolie
2 Brad Pitt @bradpitt
3 Charlie Hunnam @charliehunnam
            
                HTMLOpenTagdiv class="overflow-x-auto"HTMLCloseTag
                                                    HTMLOpenTagtable
    data-tw-merge
    class="w-full text-left"
HTMLCloseTag
    HTMLOpenTagthead
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    #
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    First Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Last Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Username
HTMLOpenTag/thHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/theadHTMLCloseTag
                                                        HTMLOpenTagtbodyHTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    1
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Angelina
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Jolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @angelinajolie
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    2
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Brad
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Pitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @bradpitt
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    3
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Charlie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Hunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @charliehunnam
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/tbodyHTMLCloseTag
HTMLOpenTag/tableHTMLCloseTag
                                                    HTMLOpenTagtable
    data-tw-merge
    class="w-full text-left bg-dark text-white dark:bg-black/30 mt-5"
HTMLCloseTag
    HTMLOpenTagthead
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    #
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    First Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Last Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Username
HTMLOpenTag/thHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/theadHTMLCloseTag
                                                        HTMLOpenTagtbodyHTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    1
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    Angelina
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    Jolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    @angelinajolie
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    2
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    Brad
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    Pitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    @bradpitt
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    3
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    Charlie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    Hunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-slate-600 dark:border-darkmode-300"
HTMLCloseTag
    @charliehunnam
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/tbodyHTMLCloseTag
HTMLOpenTag/tableHTMLCloseTag
                                                HTMLOpenTag/divHTMLCloseTag
            
        

The example above demonstrates how to create a basic table with columns for "First Name," "Last Name," and "Username." The table is easy to read and can be customized further to suit your application's needs. Use the "Basic Table" component when you want a simple, clean table structure without additional styling or complexity.

Bordered Table

The "Bordered Table" component is a variation of the basic table, with the added feature of borders around the table and its cells. This styling choice enhances the visual distinction between rows and columns, making the table content more defined and organized.

Example code / preview
# First Name Last Name Username
1 Angelina Jolie @angelinajolie
2 Brad Pitt @bradpitt
3 Charlie Hunnam @charliehunnam
            
                HTMLOpenTagdiv class="overflow-x-auto"HTMLCloseTag
                                                    HTMLOpenTagtable
    data-tw-merge
    class="w-full text-left"
HTMLCloseTag
    HTMLOpenTagthead
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-l border-r border-t whitespace-nowrap"
HTMLCloseTag
    #
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-l border-r border-t whitespace-nowrap"
HTMLCloseTag
    First Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-l border-r border-t whitespace-nowrap"
HTMLCloseTag
    Last Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-l border-r border-t whitespace-nowrap"
HTMLCloseTag
    Username
HTMLOpenTag/thHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/theadHTMLCloseTag
                                                        HTMLOpenTagtbodyHTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    1
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Angelina
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Jolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    @angelinajolie
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    2
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Brad
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Pitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    @bradpitt
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    3
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Charlie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Hunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    @charliehunnam
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/tbodyHTMLCloseTag
HTMLOpenTag/tableHTMLCloseTag
                                                HTMLOpenTag/divHTMLCloseTag
            
        

In this example, a "Bordered Table" is created with borders around the table and its cells. This added visual distinction can be particularly useful when you want to emphasize the structure of your table. Use the "Bordered Table" component when you need a table with well-defined borders to enhance the visual separation between rows and columns.

Hoverable Table

The "Hoverable Table" component is designed to enhance the user experience by adding a hover effect to the table rows. When users hover their mouse over a row, it becomes highlighted, providing a visual cue and improving interactivity.

Example code / preview
# First Name Last Name Username
1 Angelina Jolie @angelinajolie
2 Brad Pitt @bradpitt
3 Charlie Hunnam @charliehunnam
            
                HTMLOpenTagdiv class="overflow-x-auto"HTMLCloseTag
                                                    HTMLOpenTagtable
    data-tw-merge
    class="w-full text-left"
HTMLCloseTag
    HTMLOpenTagthead
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class="[&:hover_td]:bg-slate-100 [&:hover_td]:dark:bg-darkmode-300 [&:hover_td]:dark:bg-opacity-50"
HTMLCloseTag
    HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-l border-r border-t whitespace-nowrap"
HTMLCloseTag
    #
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-l border-r border-t whitespace-nowrap"
HTMLCloseTag
    First Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-l border-r border-t whitespace-nowrap"
HTMLCloseTag
    Last Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-l border-r border-t whitespace-nowrap"
HTMLCloseTag
    Username
HTMLOpenTag/thHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/theadHTMLCloseTag
                                                        HTMLOpenTagtbodyHTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class="[&:hover_td]:bg-slate-100 [&:hover_td]:dark:bg-darkmode-300 [&:hover_td]:dark:bg-opacity-50"
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    1
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Angelina
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Jolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    @angelinajolie
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class="[&:hover_td]:bg-slate-100 [&:hover_td]:dark:bg-darkmode-300 [&:hover_td]:dark:bg-opacity-50"
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    2
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Brad
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Pitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    @bradpitt
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class="[&:hover_td]:bg-slate-100 [&:hover_td]:dark:bg-darkmode-300 [&:hover_td]:dark:bg-opacity-50"
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    3
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Charlie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    Hunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 border-l border-r border-t"
HTMLCloseTag
    @charliehunnam
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/tbodyHTMLCloseTag
HTMLOpenTag/tableHTMLCloseTag
                                                HTMLOpenTag/divHTMLCloseTag
            
        

In this example, a "Hoverable Table" is created by adding the hover prop to the Table component. As users hover over rows, they visually respond by highlighting, making it easier to track their interactions. Use the "Hoverable Table" component when you want to improve user engagement and provide a more interactive experience in your table-based content.

Table Row States

The "Table Row States" feature allows you to add visual indicators to table rows, enhancing the presentation and conveying additional information to users. You can apply different styles to rows to represent various states or categories, making your tables more informative and engaging.

Example code / preview
# First Name Last Name Username
1 Angelina Jolie @angelinajolie
2 Brad Pitt @bradpitt
3 Charlie Hunnam @charliehunnam
            
                HTMLOpenTagdiv class="overflow-x-auto"HTMLCloseTag
                                                    HTMLOpenTagtable
    data-tw-merge
    class="w-full text-left"
HTMLCloseTag
    HTMLOpenTagthead
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    #
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    First Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Last Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Username
HTMLOpenTag/thHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/theadHTMLCloseTag
                                                        HTMLOpenTagtbodyHTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class="bg-primary text-white"
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    1
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Angelina
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Jolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @angelinajolie
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class="bg-danger text-white"
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    2
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Brad
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Pitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @bradpitt
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class="bg-warning"
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    3
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Charlie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Hunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @charliehunnam
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/tbodyHTMLCloseTag
HTMLOpenTag/tableHTMLCloseTag
                                                HTMLOpenTag/divHTMLCloseTag
            
        

In this example, we've applied different row states to highlight specific rows:

  • The first row is marked with a primary state, typically used for positive or highlighted content.
  • The second row is marked with a danger state, often used for indicating a critical or negative condition.
  • The third row is marked with a warning state, suitable for alerting users to a cautionary situation.

By using "Table Row States," you can visually differentiate rows based on their significance or category, making it easier for users to understand the content within the table.

Table Head Options

The "Table Head Options" feature allows you to customize the appearance of the table header to better match your application's design and styling. You can choose between two different variants: "dark" and "light," each offering a distinct visual style for the table header.

Example code / preview
# First Name Last Name Username
1 Angelina Jolie @angelinajolie
2 Brad Pitt @bradpitt
3 Charlie Hunnam @charliehunnam
# First Name Last Name Username
1 Angelina Jolie @angelinajolie
2 Brad Pitt @bradpitt
3 Charlie Hunnam @charliehunnam
            
                HTMLOpenTagdiv class="overflow-x-auto"HTMLCloseTag
                                                    HTMLOpenTagtable
    data-tw-merge
    class="w-full text-left"
HTMLCloseTag
    HTMLOpenTagthead
    data-tw-merge
    class="bg-dark text-white dark:bg-black/30"
HTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-b-0 whitespace-nowrap"
HTMLCloseTag
    #
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-b-0 whitespace-nowrap"
HTMLCloseTag
    First Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-b-0 whitespace-nowrap"
HTMLCloseTag
    Last Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-b-0 whitespace-nowrap"
HTMLCloseTag
    Username
HTMLOpenTag/thHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/theadHTMLCloseTag
                                                        HTMLOpenTagtbodyHTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    1
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Angelina
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Jolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @angelinajolie
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    2
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Brad
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Pitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @bradpitt
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    3
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Charlie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Hunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @charliehunnam
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/tbodyHTMLCloseTag
HTMLOpenTag/tableHTMLCloseTag
                                                    HTMLOpenTagtable
    data-tw-merge
    class="w-full text-left mt-5"
HTMLCloseTag
    HTMLOpenTagthead
    data-tw-merge
    class="bg-slate-200/60 dark:bg-slate-200"
HTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-b-0 text-slate-700 whitespace-nowrap"
HTMLCloseTag
    #
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-b-0 text-slate-700 whitespace-nowrap"
HTMLCloseTag
    First Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-b-0 text-slate-700 whitespace-nowrap"
HTMLCloseTag
    Last Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 border-b-0 text-slate-700 whitespace-nowrap"
HTMLCloseTag
    Username
HTMLOpenTag/thHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/theadHTMLCloseTag
                                                        HTMLOpenTagtbodyHTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    1
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Angelina
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Jolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @angelinajolie
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    2
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Brad
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Pitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @bradpitt
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    3
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Charlie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Hunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @charliehunnam
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/tbodyHTMLCloseTag
HTMLOpenTag/tableHTMLCloseTag
                                                HTMLOpenTag/divHTMLCloseTag
            
        

In this example, we showcase two different table headers using the "dark" and "light" variants:

  • The first table header is styled with the "dark" variant, which provides a dark background color and white text, creating a visually distinct header.
  • The second table header utilizes the "light" variant, offering a light background with dark text for a more subtle appearance.

By using "Table Head Options," you can align your table headers with your application's design scheme, ensuring a cohesive and aesthetically pleasing user interface.

Responsive Table

The "Responsive Table" feature ensures that your table content adapts gracefully to different screen sizes, offering an optimal viewing experience on both large desktop screens and smaller mobile devices. When you enable the "Responsive Table" component, it allows users to scroll horizontally to view the entire table, ensuring that no data is cut off on smaller screens.

Example code / preview
# First Name Last Name Username Email Address
1 Angelina Jolie @angelinajolie angelinajolie@gmail.com 260 W. Storm Street New York, NY 10025.
2 Brad Pitt @bradpitt bradpitt@gmail.com 47 Division St. Buffalo, NY 14241.
3 Charlie Hunnam @charliehunnam charliehunnam@gmail.com 8023 Amerige Street Harriman, NY 10926.
            
                HTMLOpenTagdiv class="overflow-x-auto"HTMLCloseTag
                                                    HTMLOpenTagtable
    data-tw-merge
    class="w-full text-left"
HTMLCloseTag
    HTMLOpenTagthead
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    #
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    First Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Last Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Username
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Email
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Address
HTMLOpenTag/thHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/theadHTMLCloseTag
                                                        HTMLOpenTagtbodyHTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    1
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Angelina
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Jolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    @angelinajolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    angelinajolie@gmail.com
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    260 W. Storm Street New York, NY 10025.
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    2
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Brad
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Pitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    @bradpitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    bradpitt@gmail.com
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    47 Division St. Buffalo, NY 14241.
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    3
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Charlie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Hunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    @charliehunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    charliehunnam@gmail.com
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    8023 Amerige Street Harriman, NY 10926.
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/tbodyHTMLCloseTag
HTMLOpenTag/tableHTMLCloseTag
                                                HTMLOpenTag/divHTMLCloseTag
            
        

In this example, a "Responsive Table" is created by wrapping it within a container with horizontal overflow. This allows users to scroll horizontally to view the complete table, ensuring that all columns and data remain accessible on smaller screens. Use the "Responsive Table" component when you want your table to maintain readability and usability across various devices, regardless of screen size.

Small Table

The "Small Table" component allows you to create a compact and space-efficient table, ideal for situations where you need to display tabular data in a confined space or emphasize a minimalistic design. By adding the sm (small) prop to the table, you can reduce the overall size of the table, making it more suitable for displaying information in a concise manner.

Example code / preview
# First Name Last Name Username
1 Angelina Jolie @angelinajolie
2 Brad Pitt @bradpitt
3 Charlie Hunnam @charliehunnam
            
                HTMLOpenTagdiv class="overflow-x-auto"HTMLCloseTag
                                                    HTMLOpenTagtable
    data-tw-merge
    class="w-full text-left"
HTMLCloseTag
    HTMLOpenTagthead
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 px-4 py-2 whitespace-nowrap"
HTMLCloseTag
    #
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 px-4 py-2 whitespace-nowrap"
HTMLCloseTag
    First Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 px-4 py-2 whitespace-nowrap"
HTMLCloseTag
    Last Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 px-4 py-2 whitespace-nowrap"
HTMLCloseTag
    Username
HTMLOpenTag/thHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/theadHTMLCloseTag
                                                        HTMLOpenTagtbodyHTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    1
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    Angelina
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    Jolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    @angelinajolie
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    2
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    Brad
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    Pitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    @bradpitt
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    3
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    Charlie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    Hunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300 px-4 py-2"
HTMLCloseTag
    @charliehunnam
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/tbodyHTMLCloseTag
HTMLOpenTag/tableHTMLCloseTag
                                                HTMLOpenTag/divHTMLCloseTag
            
        

In this example, a "Small Table" is created by applying the sm prop to the table component. This reduces the table's overall size, making it more compact and suitable for situations where space is limited. Use the "Small Table" component when you need to display tabular data in a constrained space or when you want to maintain a clean and minimalist design.

Striped Rows Table

The "Striped Rows Table" feature enhances the readability and visual appeal of your tables by applying alternating background colors to rows. This creates a clear distinction between even and odd rows, making it easier for users to track and interpret tabular data.

Example code / preview
# First Name Last Name Username
1 Angelina Jolie @angelinajolie
2 Brad Pitt @bradpitt
3 Charlie Hunnam @charliehunnam
            
                HTMLOpenTagdiv class="overflow-x-auto"HTMLCloseTag
                                                    HTMLOpenTagtable
    data-tw-merge
    class="w-full text-left"
HTMLCloseTag
    HTMLOpenTagthead
    data-tw-merge
    class=""
HTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class="[&:nth-of-type(odd)_td]:bg-slate-100 [&:nth-of-type(odd)_td]:dark:bg-darkmode-300 [&:nth-of-type(odd)_td]:dark:bg-opacity-50"
HTMLCloseTag
    HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    #
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    First Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Last Name
HTMLOpenTag/thHTMLCloseTag
                                                                HTMLOpenTagth
    data-tw-merge
    class="font-medium px-5 py-3 border-b-2 dark:border-darkmode-300 whitespace-nowrap"
HTMLCloseTag
    Username
HTMLOpenTag/thHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/theadHTMLCloseTag
                                                        HTMLOpenTagtbodyHTMLCloseTag
    HTMLOpenTagtr
    data-tw-merge
    class="[&:nth-of-type(odd)_td]:bg-slate-100 [&:nth-of-type(odd)_td]:dark:bg-darkmode-300 [&:nth-of-type(odd)_td]:dark:bg-opacity-50"
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    1
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Angelina
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Jolie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @angelinajolie
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class="[&:nth-of-type(odd)_td]:bg-slate-100 [&:nth-of-type(odd)_td]:dark:bg-darkmode-300 [&:nth-of-type(odd)_td]:dark:bg-opacity-50"
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    2
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Brad
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Pitt
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @bradpitt
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
                                                            HTMLOpenTagtr
    data-tw-merge
    class="[&:nth-of-type(odd)_td]:bg-slate-100 [&:nth-of-type(odd)_td]:dark:bg-darkmode-300 [&:nth-of-type(odd)_td]:dark:bg-opacity-50"
HTMLCloseTag
    HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    3
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Charlie
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    Hunnam
HTMLOpenTag/tdHTMLCloseTag
                                                                HTMLOpenTagtd
    data-tw-merge
    class="px-5 py-3 border-b dark:border-darkmode-300"
HTMLCloseTag
    @charliehunnam
HTMLOpenTag/tdHTMLCloseTag
HTMLOpenTag/trHTMLCloseTag
HTMLOpenTag/tbodyHTMLCloseTag
HTMLOpenTag/tableHTMLCloseTag
                                                HTMLOpenTag/divHTMLCloseTag
            
        

In this example, a "Striped Rows Table" is created by adding the striped prop to the table component. Even-numbered rows are styled with a background color, while odd-numbered rows remain with the default background. This alternating pattern improves the visual separation of rows and enhances the overall readability of the table. Use the "Striped Rows Table" component when you want to present tabular data in a visually organized and easy-to-read format.

Component API

In this section, you will find detailed information about the available props, classes, and options that can be used with the component. Understanding these properties is essential for customizing and configuring the component to suit your specific requirements.

Below is a list of props that can be passed to the component:

Table
Prop Type Description
`dark` `boolean` Enables dark mode styling for the table.
`bordered` `boolean` Adds borders to the table cells.
`hover` `boolean` Enables hover effects on table rows.
`striped` `boolean` Alternates row background colors for improved readability.
`sm` `boolean` Reduces the size of the table for a more compact display.
Table.Thead
Prop Type Description
`variant` `default`, `light`, `dark` Sets the variant style for the table head.
Tab.Tbody
Prop Type Description
No spesific props
Table.Tr
Prop Type Description
No spesific props
Table.Th
Prop Type Description
No spesific props
Table.Td
Prop Type Description
No spesific props