Skip to contents

Create a styled table using Designsystemet styles.

Usage

ds_table(..., size = NULL, class = NULL)

Arguments

...

Table content (thead, tbody, etc.)

size

Size variant ("sm", "md", "lg")

class

Additional CSS classes

Value

A Shiny tag object

Examples

ds_table(
  ds_thead(
    ds_tr(
      ds_th("Name"),
      ds_th("Email")
    )
  ),
  ds_tbody(
    ds_tr(
      ds_td("John Doe"),
      ds_td("john@example.com")
    )
  )
)
#> <table class="ds-table">
#>   <thead>
#>     <tr>
#>       <th scope="col">Name</th>
#>       <th scope="col">Email</th>
#>     </tr>
#>   </thead>
#>   <tbody>
#>     <tr>
#>       <td>John Doe</td>
#>       <td>john@example.com</td>
#>     </tr>
#>   </tbody>
#> </table>