Skip to content

Commit ba5843f

Browse files
authored
Merge pull request #100 from TrySound/postcss6
Postcss6
2 parents 3033372 + 5e5a4ac commit ba5843f

File tree

3 files changed

+9
-10
lines changed

3 files changed

+9
-10
lines changed

.travis.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
1-
sudo: false
21
language: node_js
32
node_js:
4-
- "0.12"
53
- "4"
6-
- "5"
4+
- "6"
5+
- "node"
76
script: npm run travis
87

98
before_install:

package.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "postcss-modules-values",
33
"version": "1.2.2",
4-
"description": "PostCSS plugin for CSS Modules to pass arbitrary constants between your module files",
4+
"description": "PostCSS plugin for CSS Modules to pass arbitrary values between your module files",
55
"main": "lib/index.js",
66
"scripts": {
77
"lint": "standard src test",
@@ -14,7 +14,7 @@
1414
},
1515
"repository": {
1616
"type": "git",
17-
"url": "git+https://github.com/css-modules/postcss-modules-constants.git"
17+
"url": "git+https://github.com/css-modules/postcss-modules-values.git"
1818
},
1919
"keywords": [
2020
"css",
@@ -24,9 +24,9 @@
2424
"author": "Glen Maddern",
2525
"license": "ISC",
2626
"bugs": {
27-
"url": "https://github.com/css-modules/postcss-modules-constants/issues"
27+
"url": "https://github.com/css-modules/postcss-modules-values/issues"
2828
},
29-
"homepage": "https://github.com/css-modules/postcss-modules-constants#readme",
29+
"homepage": "https://github.com/css-modules/postcss-modules-values#readme",
3030
"devDependencies": {
3131
"babel-cli": "^6.5.2",
3232
"babel-core": "^6.5.2",
@@ -38,7 +38,7 @@
3838
},
3939
"dependencies": {
4040
"icss-replace-symbols": "^1.0.2",
41-
"postcss": "^5.0.14"
41+
"postcss": "^6.0.1"
4242
},
4343
"babel": {
4444
"presets": [

src/index.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ let options = {}
88
let importIndex = 0
99
let createImportedName = options && options.createImportedName || ((importName/*, path*/) => `i__const_${importName.replace(/\W/g, '_')}_${importIndex++}`)
1010

11-
export default (css, result) => {
11+
export default postcss.plugin('postcss-modules-values', () => (css, result) => {
1212
let importAliases = []
1313
let definitions = {}
1414

@@ -97,4 +97,4 @@ export default (css, result) => {
9797

9898
css.prepend(importRule)
9999
})
100-
}
100+
})

0 commit comments

Comments
 (0)