Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/andrepolischuk/postcss-pseudo-class-any-button
PostCSS plugin for targeting all button elements with :any-button selector
https://github.com/andrepolischuk/postcss-pseudo-class-any-button
button postcss postcss-plugin
Last synced: 3 months ago
JSON representation
PostCSS plugin for targeting all button elements with :any-button selector
- Host: GitHub
- URL: https://github.com/andrepolischuk/postcss-pseudo-class-any-button
- Owner: andrepolischuk
- License: mit
- Created: 2015-12-23T15:24:50.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2017-04-24T11:39:33.000Z (almost 8 years ago)
- Last Synced: 2024-10-31T20:06:25.701Z (3 months ago)
- Topics: button, postcss, postcss-plugin
- Language: JavaScript
- Size: 10.7 KB
- Stars: 5
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# postcss-pseudo-class-any-button [![Build Status][travis-image]][travis-url]
> [PostCSS][postcss] plugin for targeting all button elements with `:any-button` selector
```css
/* before */.form :any-button {
border: 0;
}/* after */
.form button,
.form input[type="button"],
.form input[type="reset"],
.form input[type="submit"] {
border: 0;
}
```## Install
```sh
npm install --save-dev postcss-pseudo-class-any-button
```## Usage
### PostCSS
```js
var fs = require('fs');
var postcss = require('postcss');
var anyButton = require('postcss-pseudo-class-any-button');
var css = fs.readFileSync('input.css', 'utf8');var output = postcss([anyButton])
.process(css)
.css;
```### Gulp
```js
var gulp = require('gulp');
var postcss = require('gulp-postcss');
var anyButton = require('postcss-pseudo-class-any-button');gulp.task('css', function () {
return gulp.src('./src')
.pipe(postcss([
anyButton
]))
.pipe(gulp.dest('./dist'));
});
```## License
MIT
[travis-url]: https://travis-ci.org/andrepolischuk/postcss-pseudo-class-any-button
[travis-image]: https://travis-ci.org/andrepolischuk/postcss-pseudo-class-any-button.svg?branch=master[postcss]: https://github.com/postcss/postcss