Table Shortcode Usage
The table shortcode provides a responsive, styled table component for Hugo content.
Basic Usage
| Header 1 |
Header 2 |
Header 3 |
| Cell 1 |
Cell 2 |
Cell 3 |
| Cell 4 |
Cell 5 |
Cell 6 |
With Caption
| Header 1 |
Header 2 |
Header 3 |
| Cell 1 |
Cell 2 |
Cell 3 |
| Cell 4 |
Cell 5 |
Cell 6 |
My Table Caption
With Styling Classes
Striped Table
| Header 1 |
Header 2 |
Header 3 |
| Cell 1 |
Cell 2 |
Cell 3 |
| Cell 4 |
Cell 5 |
Cell 6 |
Compact Table
| Header 1 |
Header 2 |
Header 3 |
| Cell 1 |
Cell 2 |
Cell 3 |
| Cell 4 |
Cell 5 |
Cell 6 |
Bordered Table
| Header 1 |
Header 2 |
Header 3 |
| Cell 1 |
Cell 2 |
Cell 3 |
| Cell 4 |
Cell 5 |
Cell 6 |
Combined Options
| Operation |
Simple |
Double |
Circular |
| Insert |
O(1) |
O(1) |
O(1) |
| Delete |
O(n) |
O(1) |
O(n) |
Complexity Comparison
Available Classes
table-default (default): Standard stylingtable-striped: Alternating row colorstable-compact: Reduced padding and font sizetable-bordered: All cells have borders
Features
- Responsive: Tables scroll horizontally on small screens
- Accessible: Proper semantic HTML structure
- Customizable: Multiple styling options
- Markdown Support: Inner content is processed as markdown
- Dark Theme Compatible: Uses CSS variables for theming