File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 33> A plugin that provides utilities for centering an element on x/y axis.
44
55## The problem 🤔
6+
67Centering an element using Tailwindcss classes can rapidly become verbose.
78
89## The solution 🚀
10+
911Dedicated centering classes at component layer that cover the most common situations.
1012
1113## Install the plugin from npm:
@@ -24,7 +26,9 @@ module.exports = {
2426```
2527
2628## Usage:
29+
2730### Center on both x and y axis
31+
2832``` html
2933<div class =" relative" >
3034 <div class =" center-absolute" >
@@ -40,6 +44,7 @@ module.exports = {
4044```
4145
4246### Center on the x axis
47+
4348``` html
4449<div class =" relative" >
4550 <div class =" center-absolute-x" >
@@ -55,6 +60,7 @@ module.exports = {
5560```
5661
5762### Center on the y axis
63+
5864``` html
5965<div class =" relative" >
6066 <div class =" center-absolute-y" >
@@ -69,7 +75,7 @@ module.exports = {
6975</div >
7076```
7177
72- ## Add variants:
78+ ## Add variants:
7379
7480``` js
7581// tailwind.config.js
You can’t perform that action at this time.
0 commit comments