Skip to content
This repository was archived by the owner on Feb 1, 2020. It is now read-only.

Commit d29a5b3

Browse files
committed
update README
- add badges
1 parent e647527 commit d29a5b3

File tree

2 files changed

+39
-41
lines changed

2 files changed

+39
-41
lines changed

README.md

Lines changed: 36 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,13 @@
1-
# purgecss-webpack-plugin
2-
<!-- [![Build Status](https://travis-ci.org/FullHuman/purgecss-webpack-plugin.svg?branch=master)](https://travis-ci.org/FullHuman/purgecss-webpack-plugin)
3-
[![CircleCi](https://circleci.com/gh/FullHuman/purgecss-webpack-plugin/tree/master.svg?style=shield)]() -->
1+
# purgecss-webpack-plugin
2+
3+
[![Build Status](https://travis-ci.org/FullHuman/purgecss-webpack-plugin.svg?branch=master)](https://travis-ci.org/FullHuman/purgecss-webpack-plugin)
4+
[![CircleCi](https://circleci.com/gh/FullHuman/purgecss-webpack-plugin/tree/master.svg?style=shield)]()
45
[![dependencies Status](https://david-dm.org/fullhuman/purgecss-webpack-plugin/status.svg)](https://david-dm.org/fullhuman/purgecss-webpack-plugin)
56
[![devDependencies Status](https://david-dm.org/fullhuman/purgecss-webpack-plugin/dev-status.svg)](https://david-dm.org/fullhuman/purgecss-webpack-plugin?type=dev)
7+
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/c23bd13d30104a7a89bed239166aaf69)](https://www.codacy.com/app/FullHuman/purgecss-webpack-plugin?utm_source=github.com&utm_medium=referral&utm_content=FullHuman/purgecss-webpack-plugin&utm_campaign=Badge_Grade)
8+
[![styled with prettier](https://img.shields.io/badge/styled_with-prettier-ff69b4.svg)](https://github.com/prettier/prettier)
9+
[![npm](https://img.shields.io/npm/v/purgecss-webpack-plugin.svg)](https://www.npmjs.com/package/purgecss-webpack-plugin)
10+
[![license](https://img.shields.io/github/license/fullhuman/purgecss-webpack-plugin.svg)]()
611

712
[Webpack](https://github.com/webpack/webpack) plugin to remove unused css.
813

@@ -21,33 +26,32 @@ const ExtractTextPlugin = require('extract-text-webpack-plugin')
2126
const PurgecssPlugin = require('purgecss-webpack-plugin')
2227

2328
const PATHS = {
24-
src: path.join(__dirname, 'src')
29+
src: path.join(__dirname, 'src')
2530
}
2631

2732
module.exports = {
28-
entry: './src/index.js',
29-
output: {
30-
filename: 'bundle.js',
31-
path: path.join(__dirname, 'dist')
32-
},
33-
module: {
34-
rules: [
35-
{
36-
test: /\.css$/,
37-
use: ExtractTextPlugin.extract({
38-
fallback: 'style-loader',
39-
use: 'css-loader?sourceMap'
40-
})
41-
}
42-
]
43-
},
44-
plugins: [
45-
new ExtractTextPlugin('[name].css?[hash]'),
46-
new PurgecssPlugin({
47-
paths: glob.sync(`${PATHS.src}/*`),
48-
styleExtensions: ['.css']
33+
entry: './src/index.js',
34+
output: {
35+
filename: 'bundle.js',
36+
path: path.join(__dirname, 'dist')
37+
},
38+
module: {
39+
rules: [
40+
{
41+
test: /\.css$/,
42+
use: ExtractTextPlugin.extract({
43+
fallback: 'style-loader',
44+
use: 'css-loader?sourceMap'
4945
})
46+
}
5047
]
48+
},
49+
plugins: [
50+
new ExtractTextPlugin('[name].css?[hash]'),
51+
new PurgecssPlugin({
52+
paths: glob.sync(`${PATHS.src}/*`)
53+
})
54+
]
5155
}
5256
```
5357

@@ -57,19 +61,18 @@ Please read [CONTRIBUTING.md](./.github/CONTRIBUTING.md) for details on our code
5761

5862
## Versioning
5963

60-
We use [SemVer](http://semver.org/) for versioning.
61-
64+
We use [SemVer](http://semver.org/) for versioning.
6265

6366
## Acknowledgment
6467

6568
Purgecss was originally thought as the v2 of purifycss. And because of it, it is greatly inspired by it.
66-
The plugins such as purgecss-webpack-plugin are based on the purifycss plugin.
67-
Below is the list of the purifycss repositories:
68-
- [purifycss](https://github.com/purifycss/purifycss)
69-
- [gulp-purifycss](https://github.com/purifycss/gulp-purifycss)
70-
- [purifycss-webpack](https://github.com/webpack-contrib/purifycss-webpack)
69+
The plugins such as purgecss-webpack-plugin are based on the purifycss plugin.
70+
Below is the list of the purifycss repositories:
71+
72+
* [purifycss](https://github.com/purifycss/purifycss)
73+
* [gulp-purifycss](https://github.com/purifycss/gulp-purifycss)
74+
* [purifycss-webpack](https://github.com/webpack-contrib/purifycss-webpack)
7175

7276
## License
7377

7478
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details
75-

package.json

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@
77
"jsnext:main": "./lib/purgecss-webpack-plugin.es.js",
88
"directories": {
99
"lib": "lib",
10-
"test": "__tests__"
10+
"test": "__tests__",
11+
"example": "examples"
1112
},
1213
"scripts": {
1314
"build": "rollup -c rollup.config.js",
@@ -19,13 +20,7 @@
1920
"type": "git",
2021
"url": "git+https://github.com/FullHuman/purgecss-webpack-plugin.git"
2122
},
22-
"keywords": [
23-
"webpack-plugin",
24-
"purgecss",
25-
"remove",
26-
"unused",
27-
"css"
28-
],
23+
"keywords": ["webpack-plugin", "purgecss", "remove", "unused", "css"],
2924
"author": "Ffloriel",
3025
"license": "MIT",
3126
"bugs": {

0 commit comments

Comments
 (0)