Skip to content

Commit c39d9ea

Browse files
committed
Initial commit
0 parents  commit c39d9ea

18 files changed

+6087
-0
lines changed

.babelrc

+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
{
2+
"presets": [
3+
[
4+
"env",
5+
{
6+
"useBuiltIns": true,
7+
"targets": {
8+
"node": "4.3"
9+
},
10+
"exclude": [
11+
"transform-async-to-generator",
12+
"transform-regenerator"
13+
]
14+
}
15+
]
16+
],
17+
"plugins": [
18+
[
19+
"transform-object-rest-spread",
20+
{
21+
"useBuiltIns": true
22+
}
23+
]
24+
],
25+
"env": {
26+
"test": {
27+
"presets": [
28+
"env"
29+
],
30+
"plugins": [
31+
"transform-object-rest-spread"
32+
]
33+
}
34+
}
35+
}

.editorconfig

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# editorconfig.org
2+
3+
[*]
4+
charset = utf-8
5+
indent_style = space
6+
indent_size = 2
7+
end_of_line = lf
8+
insert_final_newline = true
9+
trim_trailing_whitespace = true
10+
11+
[.md]
12+
insert_final_newline = false
13+
trim_trailing_whitespace = false

.eslintignore

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/node_modules
2+
/dist

.eslintrc

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"extends": "webpack",
3+
"rules": {
4+
"class-methods-use-this": "off",
5+
"no-undefined": "off"
6+
}
7+
}

.gitattributes

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
package-lock.json -diff
2+
* text=auto
3+
bin/* eol=lf

.github/ISSUE_TEMPLATE.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<!--
2+
1. Check the version of package you are using. If it's not the newest version, update and try again (see changelog while updating!).
3+
2. If the issue is still there, write a minimal project showing the problem and expected output.
4+
3. Link to the project and mention Node version and OS in your report.
5+
6+
**IMPORTANT! You should use [Stack Overflow](https://stackoverflow.com/) for support related questions.**
7+
-->

.github/PULL_REQUEST_TEMPLATE.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<!--
2+
1. [Read and sign the CLA](https://cla.js.foundation/webpack/webpack.js.org). This needs to be done only once. PRs that haven't signed it won't be accepted.
3+
2. Check out the [development guide](https://webpack.js.org/development/) for the API and development guidelines.
4+
3. Read through the PR diff carefully as sometimes this can reveal issues. The work will be reviewed, but this can save some effort.
5+
-->

.gitignore

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
logs
2+
*.log
3+
npm-debug.log*
4+
.eslintcache
5+
/coverage
6+
/dist
7+
/local
8+
/reports
9+
/node_modules
10+
.DS_Store
11+
Thumbs.db
12+
.idea
13+
.vscode
14+
*.sublime-project
15+
*.sublime-workspace

.travis.yml

+48
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
sudo: false
2+
dist: trusty
3+
language: node_js
4+
branches:
5+
only:
6+
- master
7+
jobs:
8+
fast_finish: true
9+
allow_failures:
10+
- env: WEBPACK_VERSION=canary
11+
include:
12+
- &test-latest
13+
stage: Webpack latest
14+
node_js: 6
15+
env: WEBPACK_VERSION=latest JOB_PART=test
16+
script: npm run travis:$JOB_PART
17+
- <<: *test-latest
18+
node_js: 4.8
19+
env: WEBPACK_VERSION=latest JOB_PART=test
20+
script: npm run travis:$JOB_PART
21+
- <<: *test-latest
22+
node_js: 8
23+
env: WEBPACK_VERSION=latest JOB_PART=lint
24+
script: npm run travis:$JOB_PART
25+
- <<: *test-latest
26+
node_js: 8
27+
env: WEBPACK_VERSION=latest JOB_PART=coverage
28+
script: npm run travis:$JOB_PART
29+
after_success: 'bash <(curl -s https://codecov.io/bash)'
30+
- stage: Webpack canary
31+
before_script: npm i --no-save git://github.com/webpack/webpack.git#master
32+
script: npm run travis:$JOB_PART
33+
node_js: 8
34+
env: WEBPACK_VERSION=canary JOB_PART=test
35+
before_install:
36+
- 'if [[ `npm -v` != 5* ]]; then npm i -g npm@^5.0.0; fi'
37+
- nvm --version
38+
- node --version
39+
- npm --version
40+
before_script:
41+
- |-
42+
if [ "$WEBPACK_VERSION" ]; then
43+
npm i --no-save webpack@$WEBPACK_VERSION
44+
fi
45+
script:
46+
- 'npm run travis:$JOB_PART'
47+
after_success:
48+
- 'bash <(curl -s https://codecov.io/bash)'

CHANGELOG.md

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Change Log
2+
3+
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4+
5+
x.x.x / <year>-<month>-<day>
6+
==================
7+
8+
* Bug fix -
9+
* Feature -
10+
* Chore -
11+
* Docs -

LICENSE

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
Copyright JS Foundation and other contributors
2+
3+
Permission is hereby granted, free of charge, to any person obtaining
4+
a copy of this software and associated documentation files (the
5+
'Software'), to deal in the Software without restriction, including
6+
without limitation the rights to use, copy, modify, merge, publish,
7+
distribute, sublicense, and/or sell copies of the Software, and to
8+
permit persons to whom the Software is furnished to do so, subject to
9+
the following conditions:
10+
11+
The above copyright notice and this permission notice shall be
12+
included in all copies or substantial portions of the Software.
13+
14+
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
15+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
17+
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
18+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
19+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
20+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

README.md

+112
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,112 @@
1+
[![npm][npm]][npm-url]
2+
[![deps][deps]][deps-url]
3+
[![test][test]][test-url]
4+
[![coverage][cover]][cover-url]
5+
[![chat][chat]][chat-url]
6+
7+
<div align="center">
8+
<!-- replace with accurate logo e.g from https://worldvectorlogo.com/ -->
9+
<img width="200" height="200" src="https://cdn.worldvectorlogo.com/logos/javascript.svg">
10+
<a href="https://webpack.js.org/">
11+
<img width="200" height="200" vspace="" hspace="25" src="https://cdn.rawgit.com/webpack/media/e7485eb2/logo/icon-square-big.svg">
12+
</a>
13+
<h1>mini-css-extract-plugin</h1>
14+
<p>desc</p>
15+
</div>
16+
17+
<h2 align="center">Install</h2>
18+
19+
```bash
20+
npm install --save-dev mini-css-extract-plugin
21+
```
22+
23+
<h2 align="center">Usage</h2>
24+
25+
### Lorem
26+
27+
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
28+
29+
<h2 align="center">Examples</h2>
30+
31+
**webpack.config.js**
32+
33+
```js
34+
// Loader/plugin setup here..
35+
```
36+
37+
**file.ext**
38+
39+
```js
40+
// Source code here...
41+
```
42+
43+
**bundle.js**
44+
45+
```js
46+
require("mini-css-extract-plugin!./file.EXT");
47+
48+
// Bundle code here...
49+
```
50+
51+
<h2 align="center">Maintainers</h2>
52+
53+
```bash
54+
https://api.github.com/users/MAINTAINER
55+
```
56+
57+
<table>
58+
<tbody>
59+
<tr>
60+
<td align="center">
61+
<a href="https://github.com/">
62+
<img width="150" height="150" src="https://avatars.githubusercontent.com/u/5419992?v=3&s=150">
63+
</br>
64+
Name
65+
</a>
66+
</td>
67+
<td align="center">
68+
<a href="https://github.com/">
69+
<img width="150" height="150" src="https://avatars.githubusercontent.com/u/5419992?v=3&s=150">
70+
</br>
71+
Name
72+
</a>
73+
</td>
74+
<td align="center">
75+
<a href="https://github.com/">
76+
<img width="150" height="150" src="https://avatars.githubusercontent.com/u/5419992?v=3&s=150">
77+
</br>
78+
Name
79+
</a>
80+
</td>
81+
<td align="center">
82+
<a href="https://github.com/">
83+
<img width="150" height="150" src="https://avatars.githubusercontent.com/u/5419992?v=3&s=150">
84+
</br>
85+
Name
86+
</a>
87+
</td>
88+
<td align="center">
89+
<a href="https://github.com/">
90+
<img width="150" height="150" src="https://avatars.githubusercontent.com/u/5419992?v=3&s=150">
91+
</br>
92+
Name
93+
</a>
94+
</td>
95+
</tr>
96+
<tbody>
97+
</table>
98+
99+
[npm]: https://img.shields.io/npm/v/mini-css-extract-plugin.svg
100+
[npm-url]: https://npmjs.com/package/mini-css-extract-plugin
101+
102+
[deps]: https://david-dm.org/webpack-contrib/mini-css-extract-plugin.svg
103+
[deps-url]: https://david-dm.org/webpack-contrib/mini-css-extract-plugin
104+
105+
[chat]: https://img.shields.io/badge/gitter-webpack%2Fwebpack-brightgreen.svg
106+
[chat-url]: https://gitter.im/webpack/webpack
107+
108+
[test]: http://img.shields.io/travis/webpack-contrib/mini-css-extract-plugin.svg
109+
[test-url]: https://travis-ci.org/webpack-contrib/mini-css-extract-plugin
110+
111+
[cover]: https://codecov.io/gh/webpack-contrib/mini-css-extract-plugin/branch/master/graph/badge.svg
112+
[cover-url]: https://codecov.io/gh/webpack-contrib/mini-css-extract-plugin

appveyor.yml

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
branches:
2+
only:
3+
- master
4+
init:
5+
- git config --global core.autocrlf input
6+
environment:
7+
matrix:
8+
- nodejs_version: '8'
9+
webpack_version: latest
10+
job_part: test
11+
- nodejs_version: '6'
12+
webpack_version: latest
13+
job_part: test
14+
- nodejs_version: '4.3'
15+
webpack_version: latest
16+
job_part: test
17+
build: 'off'
18+
matrix:
19+
fast_finish: true
20+
install:
21+
- 'ps: Install-Product node $env:nodejs_version x64'
22+
- npm i -g npm@latest
23+
- npm install
24+
before_test:
25+
- 'cmd: npm install webpack@%webpack_version%'
26+
test_script:
27+
- node --version
28+
- npm --version
29+
- 'cmd: npm run appveyor:%job_part%'

package.json

+64
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
{
2+
"name": "mini-css-extract-plugin",
3+
"version": "0.1.0",
4+
"description": "desc",
5+
"main": "dist/cjs.js",
6+
"repository": "https://github.com/webpack-contrib/mini-css-extract-plugin",
7+
"author": "Tobias Koppers @sokra",
8+
"license": "MIT",
9+
"private": false,
10+
"scripts": {
11+
"webpack-defaults": "webpack-defaults",
12+
"start": "npm run build -- -w",
13+
"appveyor:test": "npm run test",
14+
"build": "cross-env NODE_ENV=production babel src -d dist --ignore 'src/**/*.test.js'",
15+
"clean": "del-cli dist",
16+
"lint": "eslint --cache src test",
17+
"lint-staged": "lint-staged",
18+
"prebuild": "npm run clean",
19+
"prepublish": "npm run build",
20+
"release": "standard-version",
21+
"security": "nsp check",
22+
"test": "jest",
23+
"test:watch": "jest --watch",
24+
"test:coverage": "jest --collectCoverageFrom='src/**/*.js' --coverage",
25+
"travis:lint": "npm run lint && npm run security",
26+
"travis:test": "npm run test -- --runInBand",
27+
"travis:coverage": "npm run test:coverage -- --runInBand"
28+
},
29+
"devDependencies": {
30+
"babel-cli": "^6.26.0",
31+
"babel-jest": "^22.2.2",
32+
"babel-plugin-transform-object-rest-spread": "^6.26.0",
33+
"babel-polyfill": "^6.26.0",
34+
"babel-preset-env": "^1.6.1",
35+
"cross-env": "^5.1.3",
36+
"del-cli": "^1.1.0",
37+
"eslint": "^4.17.0",
38+
"eslint-config-webpack": "^1.2.5",
39+
"eslint-plugin-import": "^2.8.0",
40+
"jest": "^22.2.2",
41+
"lint-staged": "^6.1.0",
42+
"nsp": "^3.1.0",
43+
"pre-commit": "^1.2.2",
44+
"standard-version": "^4.3.0",
45+
"webpack": "^3.11.0",
46+
"webpack-defaults": "^1.6.0"
47+
},
48+
"files": [
49+
"dist"
50+
],
51+
"engines": {
52+
"node": ">= 4.3 < 5.0.0 || >= 5.10"
53+
},
54+
"peerDependencies": {
55+
"webpack": "^2.0.0 || ^3.0.0"
56+
},
57+
"pre-commit": "lint-staged",
58+
"lint-staged": {
59+
"*.js": [
60+
"eslint --fix",
61+
"git add"
62+
]
63+
}
64+
}

src/cjs.js

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
module.exports = require('./index').default;

0 commit comments

Comments
 (0)