everycss-mixin
Add mixin, include and extend support
Last updated 6 years ago by cahnory .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install everycss-mixin 
SYNC missed versions from official npm registry.

#EveryCSS-mixin

Add mixin, include and extend support

##@include

@mixin demo {
  border: 1px solid red;
  color: red;
  font-weight: bold;
}

.demo1 {
  @include demo;
}
.demo2 {
  background: black;
  @include demo;
}
.demo3 {
  background: white;
  @include demo;
}

output:

.demo1 {
  border: 1px solid red;
  color: red;
  font-weight: bold;
}
.demo2 {
  background: black;
  border: 1px solid red;
  color: red;
  font-weight: bold;
}
.demo3 {
  background: white;
  border: 1px solid red;
  color: red;
  font-weight: bold;
}

##@extend

@mixin demo {
  border: 1px solid red;
  color: red;
  font-weight: bold;
}

.demo1 {
  @include demo;
}
.demo2 {
  background: black;
  @extend demo;
}
.demo3 {
  background: white;
  @extend demo;
}

output:

.demo2, .demo3 {
  border: 1px solid red;
  color: red;
  font-weight: bold;
}
.demo1 {
  border: 1px solid red;
  color: red;
  font-weight: bold;
}
.demo2 {
  background: black;
}
.demo3 {
  background: white;
}

Current Tags

  • 0.1.0                                ...           latest (6 years ago)

1 Versions

  • 0.1.0                                ...           6 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (0)
None
Dev Dependencies (1)
Dependents (2)

Copyright 2014 - 2017 © taobao.org |