Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upgrade css-modules-loader-core for Values support #47

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// Some css-modules-loader-code dependencies use Promise so we'll provide it for older node versions
if (!global.Promise) { global.Promise = require('promise-polyfill') }

var fs = require('fs');
var path = require('path');
var through = require('through');
Expand All @@ -6,7 +9,6 @@ var FileSystemLoader = require('css-modules-loader-core/lib/file-system-loader')
var assign = require('object-assign');
var stringHash = require('string-hash');


/*
Custom `generateScopedName` function for `postcss-modules-scope`.
Short names consisting of source hash and line number.
Expand Down Expand Up @@ -46,7 +48,8 @@ function getDefaultPlugins (options) {
scope.generateScopedName = customNameFunc || defaultNameFunc;

return [
Core.localByDefault
Core.values
, Core.localByDefault
, Core.extractImports
, scope
];
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
"description": "A browserify transform to load CSS Modules",
"main": "index.js",
"dependencies": {
"css-modules-loader-core": "0.0.12",
"css-modules-loader-core": "^1.0.0-beta4",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This would just change to "^1.0.0"

"promise-polyfill": "^2.1.0",
"object-assign": "^3.0.0",
"string-hash": "^1.1.0",
"through": "^2.3.7"
Expand Down