This module has been moved to the monorepo wocss (and renamed to
@wocss/tools-layout
)
Tool
The wocss-tools-layout
module contains a few mixins
to help tame those layouts.
Install using npm:
$ npm install wocss-tools-layout --save
With a tool like webpack you can import this module writing:
@import '~wocss-tools-layout';
Then you can use these mixins:
Center the element.
.container {
@include layout-center(1000px, false);
}
Result:
.container {
display: block;
margin-left: auto;
margin-right: auto;
max-width: 1000px;
width: 100%;
}
It makes an element a block.
.container {
@include layout-block();
}
Result:
.container {
display: block;
width: 100%;
padding-left: 1.5rem;
padding-right: 1.5rem;
}