aboutsummaryrefslogtreecommitdiff
path: root/_posts/2024-02-23-Please_Make_Your_Table_Headings_Sticky.md
diff options
context:
space:
mode:
Diffstat (limited to '_posts/2024-02-23-Please_Make_Your_Table_Headings_Sticky.md')
-rw-r--r--_posts/2024-02-23-Please_Make_Your_Table_Headings_Sticky.md6
1 files changed, 4 insertions, 2 deletions
diff --git a/_posts/2024-02-23-Please_Make_Your_Table_Headings_Sticky.md b/_posts/2024-02-23-Please_Make_Your_Table_Headings_Sticky.md
index c9005e4..6d71cb2 100644
--- a/_posts/2024-02-23-Please_Make_Your_Table_Headings_Sticky.md
+++ b/_posts/2024-02-23-Please_Make_Your_Table_Headings_Sticky.md
@@ -23,8 +23,10 @@ Your browser does not support the video tag.
Pretty awesome, right? It might look like magic but it's actually very easy to implement. You only need to add 2 CSS properties on your `thead`:
- position: sticky;
- top: 0;
+```css
+position: sticky;
+top: 0;
+```
That's it! Best of all, `sticky` has [~96% global support](https://caniuse.com/?search=sticky) which means this isn't some "bleeding-edge" property and can safely support a ton of browsers. Not to mention the improved experience for your end-users!