https://github.com/koala-framework/postcss-prefixer-font-face
https://github.com/koala-framework/postcss-prefixer-font-face
Last synced: over 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/koala-framework/postcss-prefixer-font-face
- Owner: koala-framework
- License: bsd-2-clause
- Created: 2015-11-20T07:48:28.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2016-05-18T10:09:20.000Z (about 10 years ago)
- Last Synced: 2025-01-20T05:40:20.412Z (over 1 year ago)
- Language: JavaScript
- Size: 1.95 KB
- Stars: 1
- Watchers: 6
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# PostCSS Prefixer font-face
[PostCSS] plugin to prefix font-faces.
[PostCSS]: https://github.com/postcss/postcss
```css
/* Input example */
@font-face {
font-family: MyWebFont;
}
div {
width: 100px;
background: red;
position: relative;
font-family: Arial;
}
a {
color: green;
position: relative;
font-family: MyWebFont;
}
```
```css
/* Output example */
@font-face {
font-family: myWebsite-MyWebFont;
}
div {
width: 100px;
background: red;
position: relative;
font-family: Arial;
}
a {
color: green;
position: relative;
font-family: myWebsite-MyWebFont;
}
```
## Usage
```js
var prefix = require('postcss-prefixer-font-face');
postcss([ prefix({prefix: 'myWebsite-'}) ])
```
See [PostCSS] docs for examples for your environment.