Skip to content

Commit

Permalink
Merge 53a7817 into 276324c
Browse files Browse the repository at this point in the history
  • Loading branch information
jhnns committed Feb 21, 2017
2 parents 276324c + 53a7817 commit 84bae1a
Show file tree
Hide file tree
Showing 12 changed files with 83 additions and 85 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ npm-debug.log
/node_modules
coverage
.idea
.nyc_output
19 changes: 0 additions & 19 deletions .npmignore

This file was deleted.

4 changes: 4 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,7 @@ node_js:
- "7"
- "6"
- "4"

after_success:
- npm install coveralls
- npm run coverage && cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js && rm -rf ./coverage
78 changes: 39 additions & 39 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,118 +3,118 @@ Changelog

### 6.0.2

- Update dependencies [#383](https://github.com/jtangelder/sass-loader/pull/383)
- Update dependencies [#383](https://github.com/webpack-contrib/sass-loader/pull/383)

### 6.0.1

- Fix source maps in certain CWDs. [#377](https://github.com/jtangelder/sass-loader/pull/377)
- Fix source maps in certain CWDs. [#377](https://github.com/webpack-contrib/sass-loader/pull/377)

### 6.0.0

- **Breaking** (for resolve-url-loader only): Improve source map support. [#374](https://github.com/jtangelder/sass-loader/issues/374)
- **Breaking** (for resolve-url-loader only): Improve source map support. [#374](https://github.com/webpack-contrib/sass-loader/issues/374)

### 5.0.1

- Fix bug where multiple compilations interfered with each other. [#369](https://github.com/jtangelder/sass-loader/pull/369)
- Fix bug where multiple compilations interfered with each other. [#369](https://github.com/webpack-contrib/sass-loader/pull/369)

### 5.0.0

- **Breaking**: Remove synchronous compilation support. [#334](https://github.com/jtangelder/sass-loader/pull/334)
- **Breaking**: Remove official node-sass@3 and webpack@1 support. [5a6bcb96d8bd7a7a11c33252ba739ffe09ca38c5](https://github.com/jtangelder/sass-loader/commit/5a6bcb96d8bd7a7a11c33252ba739ffe09ca38c5)
- **Breaking**: Remove node 0.12 support. [29b30755021a834e622bf4b5bb9db4d6e5913905](https://github.com/jtangelder/sass-loader/commit/29b30755021a834e622bf4b5bb9db4d6e5913905)
- **Breaking**: Remove synchronous compilation support. [#334](https://github.com/webpack-contrib/sass-loader/pull/334)
- **Breaking**: Remove official node-sass@3 and webpack@1 support. [5a6bcb96d8bd7a7a11c33252ba739ffe09ca38c5](https://github.com/webpack-contrib/sass-loader/commit/5a6bcb96d8bd7a7a11c33252ba739ffe09ca38c5)
- **Breaking**: Remove node 0.12 support. [29b30755021a834e622bf4b5bb9db4d6e5913905](https://github.com/webpack-contrib/sass-loader/commit/29b30755021a834e622bf4b5bb9db4d6e5913905)

### 4.1.1

- Update `webpack` peer dependency to support `2.2.0rc`. [#330](https://github.com/jtangelder/sass-loader/pull/330)
- Update `webpack` peer dependency to support `2.2.0rc`. [#330](https://github.com/webpack-contrib/sass-loader/pull/330)

### 4.1.0

- Update `node-sass@4.0.0` [#319](https://github.com/jtangelder/sass-loader/pull/319)
- Update `node-sass@4.0.0` [#319](https://github.com/webpack-contrib/sass-loader/pull/319)

### 4.0.2

- Fix wrong context in customImporters that was introduced with fd6be1f143a1810f7e5072a865b3d8675ba1b94e [#275](https://github.com/jtangelder/sass-loader/issues/275) [#277](https://github.com/jtangelder/sass-loader/pull/277)
- Fix wrong context in customImporters that was introduced with fd6be1f143a1810f7e5072a865b3d8675ba1b94e [#275](https://github.com/webpack-contrib/sass-loader/issues/275) [#277](https://github.com/webpack-contrib/sass-loader/pull/277)

### 4.0.1

- Fix custom importers receiving `'stdin'` as second argument instead of the actual `resourcePath` [#267](https://github.com/jtangelder/sass-loader/pull/267)
- Fix custom importers receiving `'stdin'` as second argument instead of the actual `resourcePath` [#267](https://github.com/webpack-contrib/sass-loader/pull/267)

### 4.0.0

- **Breaking**: Release new major version because `3.2.2` was a breaking change in certain scenarios [#250](https://github.com/jtangelder/sass-loader/pull/250) [#254](https://github.com/jtangelder/sass-loader/issues/254)
- **Breaking**: Release new major version because `3.2.2` was a breaking change in certain scenarios [#250](https://github.com/webpack-contrib/sass-loader/pull/250) [#254](https://github.com/webpack-contrib/sass-loader/issues/254)

### 3.2.3

- Revert changes to `3.2.1` because `3.2.2` contained a potential breaking change [#254](https://github.com/jtangelder/sass-loader/issues/254)
- Revert changes to `3.2.1` because `3.2.2` contained a potential breaking change [#254](https://github.com/webpack-contrib/sass-loader/issues/254)

### 3.2.2

- Fix incorrect source map paths [#250](https://github.com/jtangelder/sass-loader/pull/250)
- Fix incorrect source map paths [#250](https://github.com/webpack-contrib/sass-loader/pull/250)

### 3.2.1

- Add `webpack@^2.1.0-beta` as peer dependency [#233](https://github.com/jtangelder/sass-loader/pull/233)
- Add `webpack@^2.1.0-beta` as peer dependency [#233](https://github.com/webpack-contrib/sass-loader/pull/233)

### 3.2.0

- Append file content instead of overwriting when `data`-option is already present [#216](https://github.com/jtangelder/sass-loader/pull/216)
- Make `indentedSyntax` option a bit smarter [#196](https://github.com/jtangelder/sass-loader/pull/196)
- Append file content instead of overwriting when `data`-option is already present [#216](https://github.com/webpack-contrib/sass-loader/pull/216)
- Make `indentedSyntax` option a bit smarter [#196](https://github.com/webpack-contrib/sass-loader/pull/196)

### 3.1.2

- Fix loader query not overriding webpack config [#189](https://github.com/jtangelder/sass-loader/pull/189)
- Update peer-dependencies [#182](https://github.com/jtangelder/sass-loader/pull/182)
- Fix loader query not overriding webpack config [#189](https://github.com/webpack-contrib/sass-loader/pull/189)
- Update peer-dependencies [#182](https://github.com/webpack-contrib/sass-loader/pull/182)
- `node-sass@^3.4.2`
- `webpack@^1.12.6`

### 3.1.1

- Fix missing module `object-assign` [#178](https://github.com/jtangelder/sass-loader/issues/178)
- Fix missing module `object-assign` [#178](https://github.com/webpack-contrib/sass-loader/issues/178)

### 3.1.0

- Add possibility to also define all options in your `webpack.config.js` [#152](https://github.com/jtangelder/sass-loader/pull/152) [#170](https://github.com/jtangelder/sass-loader/pull/170)
- Fix a problem where modules with a `.` in their names were not resolved [#167](https://github.com/jtangelder/sass-loader/issues/167)
- Add possibility to also define all options in your `webpack.config.js` [#152](https://github.com/webpack-contrib/sass-loader/pull/152) [#170](https://github.com/webpack-contrib/sass-loader/pull/170)
- Fix a problem where modules with a `.` in their names were not resolved [#167](https://github.com/webpack-contrib/sass-loader/issues/167)

### 3.0.0

- **Breaking:** Add `node-sass@^3.3.3` and `webpack@^1.12.2` as peer-dependency [#165](https://github.com/jtangelder/sass-loader/pull/165) [#166](https://github.com/jtangelder/sass-loader/pull/166) [#169](https://github.com/jtangelder/sass-loader/pull/169)
- Fix crash when Sass reported an error without `file` [#158](https://github.com/jtangelder/sass-loader/pull/158)
- **Breaking:** Add `node-sass@^3.3.3` and `webpack@^1.12.2` as peer-dependency [#165](https://github.com/webpack-contrib/sass-loader/pull/165) [#166](https://github.com/webpack-contrib/sass-loader/pull/166) [#169](https://github.com/webpack-contrib/sass-loader/pull/169)
- Fix crash when Sass reported an error without `file` [#158](https://github.com/webpack-contrib/sass-loader/pull/158)

### 2.0.1

- Add missing path normalization [#141](https://github.com/jtangelder/sass-loader/pull/141)
- Add missing path normalization [#141](https://github.com/webpack-contrib/sass-loader/pull/141)

### 2.0.0

- **Breaking:** Refactor [import resolving algorithm](https://github.com/jtangelder/sass-loader/blob/089c52dc9bd02ec67fb5c65c2c226f43710f231c/index.js#L293-L348). The new algorithm is aligned to libsass' way of resolving files. This yields to different results if two files with the same path and filename but with different extensions are present. Though this change should be no problem for most users, we must flag it as breaking change. [#135](https://github.com/jtangelder/sass-loader/issues/135) [#138](https://github.com/jtangelder/sass-loader/issues/138)
- Add temporary fix for stuck processes (see [sass/node-sass#857](https://github.com/sass/node-sass/issues/857)) [#100](https://github.com/jtangelder/sass-loader/issues/100) [#119](https://github.com/jtangelder/sass-loader/issues/119) [#132](https://github.com/jtangelder/sass-loader/pull/132)
- Fix path resolving on Windows [#108](https://github.com/jtangelder/sass-loader/issues/108)
- Fix file watchers on Windows [#102](https://github.com/jtangelder/sass-loader/issues/102)
- Fix file watchers for files with errors [#134](https://github.com/jtangelder/sass-loader/pull/134)
- **Breaking:** Refactor [import resolving algorithm](https://github.com/webpack-contrib/sass-loader/blob/089c52dc9bd02ec67fb5c65c2c226f43710f231c/index.js#L293-L348). The new algorithm is aligned to libsass' way of resolving files. This yields to different results if two files with the same path and filename but with different extensions are present. Though this change should be no problem for most users, we must flag it as breaking change. [#135](https://github.com/webpack-contrib/sass-loader/issues/135) [#138](https://github.com/webpack-contrib/sass-loader/issues/138)
- Add temporary fix for stuck processes (see [sass/node-sass#857](https://github.com/sass/node-sass/issues/857)) [#100](https://github.com/webpack-contrib/sass-loader/issues/100) [#119](https://github.com/webpack-contrib/sass-loader/issues/119) [#132](https://github.com/webpack-contrib/sass-loader/pull/132)
- Fix path resolving on Windows [#108](https://github.com/webpack-contrib/sass-loader/issues/108)
- Fix file watchers on Windows [#102](https://github.com/webpack-contrib/sass-loader/issues/102)
- Fix file watchers for files with errors [#134](https://github.com/webpack-contrib/sass-loader/pull/134)

### 1.0.4

- Fix wrong source-map urls [#123](https://github.com/jtangelder/sass-loader/pull/123)
- Include source-map contents by default [#104](https://github.com/jtangelder/sass-loader/pull/104)
- Fix wrong source-map urls [#123](https://github.com/webpack-contrib/sass-loader/pull/123)
- Include source-map contents by default [#104](https://github.com/webpack-contrib/sass-loader/pull/104)

### 1.0.3

- Fix importing css files from scss/sass [#101](https://github.com/jtangelder/sass-loader/issues/101)
- Fix importing Sass partials from includePath [#98](https://github.com/jtangelder/sass-loader/issues/98) [#110](https://github.com/jtangelder/sass-loader/issues/110)
- Fix importing css files from scss/sass [#101](https://github.com/webpack-contrib/sass-loader/issues/101)
- Fix importing Sass partials from includePath [#98](https://github.com/webpack-contrib/sass-loader/issues/98) [#110](https://github.com/webpack-contrib/sass-loader/issues/110)

### 1.0.2

- Fix a bug where files could not be imported across language styles [#73](https://github.com/jtangelder/sass-loader/issues/73)
- Fix a bug where files could not be imported across language styles [#73](https://github.com/webpack-contrib/sass-loader/issues/73)
- Update peer-dependency `node-sass` to `3.1.0`

### 1.0.1

- Fix Sass partials not being resolved anymore [#68](https://github.com/jtangelder/sass-loader/issues/68)
- Fix Sass partials not being resolved anymore [#68](https://github.com/webpack-contrib/sass-loader/issues/68)
- Update peer-dependency `node-sass` to `3.0.0-beta.4`

### 1.0.0

- Moved `node-sass^3.0.0-alpha.0` to `peerDependencies` [#28](https://github.com/jtangelder/sass-loader/issues/28)
- Using webpack's module resolver as custom importer [#39](https://github.com/jtangelder/sass-loader/issues/31)
- Add synchronous compilation support for usage with [enhanced-require](https://github.com/webpack/enhanced-require) [#39](https://github.com/jtangelder/sass-loader/pull/39)
- Moved `node-sass^3.0.0-alpha.0` to `peerDependencies` [#28](https://github.com/webpack-contrib/sass-loader/issues/28)
- Using webpack's module resolver as custom importer [#39](https://github.com/webpack-contrib/sass-loader/issues/31)
- Add synchronous compilation support for usage with [enhanced-require](https://github.com/webpack/enhanced-require) [#39](https://github.com/webpack-contrib/sass-loader/pull/39)
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015 J. Tangelder
Copyright JS Foundation and other contributors

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
Expand Down
29 changes: 17 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
[![npm][npm]][npm-url]
[![npm-version][npm-version]][npm-url]
[![npm-stats][npm-stats]][npm-url]
[![deps][deps]][deps-url]
[![test][test]][test-url]
[![travis][travis]][travis-url]
[![coverage][coverage]][coverage-url]

<div align="center">
<img height="100"
Expand All @@ -11,7 +13,7 @@
</a>
<h1>sass-loader</h1>
<p>Compiles Sass to CSS.<br>Use the <a href="https://github.com/webpack/css-loader">css-loader</a> or the <a href="https://github.com/webpack/raw-loader">raw-loader</a> to turn it into a JS module and the <a href="https://github.com/webpack/extract-text-webpack-plugin">ExtractTextPlugin</a> to extract it into a separate file.<p>
<p>Looking for the webpack 1 loader? Check out the <a href="https://github.com/jtangelder/sass-loader/tree/archive/webpack-1">archive/webpack-1 branch</a>.</p>
<p>Looking for the webpack 1 loader? Check out the <a href="https://github.com/webpack-contrib/sass-loader/tree/archive/webpack-1">archive/webpack-1 branch</a>.</p>
</div>

## Install
Expand Down Expand Up @@ -142,7 +144,7 @@ Since Sass/[libsass](https://github.com/sass/libsass) does not provide [url rewr
More likely you will be disrupted by this second issue. It is natural to expect relative references to be resolved against the `.scss` file in which they are specified (like in regular `.css` files). Thankfully there are a two solutions to this problem:

- Add the missing url rewriting using the [resolve-url-loader](https://github.com/bholloway/resolve-url-loader). Place it directly after the sass-loader in the loader chain.
- Library authors usually provide a variable to modify the asset path. [bootstrap-sass](https://github.com/twbs/bootstrap-sass) for example has an `$icon-font-path`. Check out [this working bootstrap example](https://github.com/jtangelder/sass-loader/tree/master/test/bootstrapSass).
- Library authors usually provide a variable to modify the asset path. [bootstrap-sass](https://github.com/twbs/bootstrap-sass) for example has an `$icon-font-path`. Check out [this working bootstrap example](https://github.com/webpack-contrib/sass-loader/tree/master/test/bootstrapSass).

### Extracting stylesheets

Expand Down Expand Up @@ -180,7 +182,7 @@ module.exports = {
};
```

If you want to edit the original Sass files inside Chrome, [there's a good blog post](https://medium.com/@toolmantim/getting-started-with-css-sourcemaps-and-in-browser-sass-editing-b4daab987fb0). Checkout [test/sourceMap](https://github.com/jtangelder/sass-loader/tree/master/test) for a running example.
If you want to edit the original Sass files inside Chrome, [there's a good blog post](https://medium.com/@toolmantim/getting-started-with-css-sourcemaps-and-in-browser-sass-editing-b4daab987fb0). Checkout [test/sourceMap](https://github.com/webpack-contrib/sass-loader/tree/master/test) for a running example.


## Maintainers
Expand All @@ -196,7 +198,7 @@ If you want to edit the original Sass files inside Chrome, [there's a good blog
<td align="center">
<img width="150 height="150"
src="https://avatars1.githubusercontent.com/u/1243901?v=3&s=460"><br>
<a href="https://github.com/jtangelder">Jorik Tangelder</a>
<a href="https://github.com/webpack-contrib">Jorik Tangelder</a>
</td>
<td align="center">
<img width="150" height="150"
Expand All @@ -212,12 +214,15 @@ If you want to edit the original Sass files inside Chrome, [there's a good blog

[MIT](http://www.opensource.org/licenses/mit-license.php)


[npm]: https://img.shields.io/npm/v/sass-loader.svg
[npm-version]: https://img.shields.io/npm/v/sass-loader.svg
[npm-stats]: https://img.shields.io/npm/dm/sass-loader.svg
[npm-url]: https://npmjs.com/package/sass-loader

[deps]: https://david-dm.org/jtangelder/sass-loader.svg
[deps-url]: https://david-dm.org/jtangelder/sass-loader
[deps]: https://david-dm.org/webpack-contrib/sass-loader.svg
[deps-url]: https://david-dm.org/webpack-contrib/sass-loader

[travis]: http://img.shields.io/travis/webpack-contrib/sass-loader.svg
[travis-url]: https://travis-ci.org/webpack-contrib/sass-loader

[test]: http://img.shields.io/travis/jtangelder/sass-loader.svg
[test-url]: https://travis-ci.org/jtangelder/sass-loader
[coverage]: https://img.shields.io/coveralls/webpack-contrib/sass-loader.svg
[coverage-url]: https://coveralls.io/r/webpack-contrib/sass-loader?branch=master
2 changes: 1 addition & 1 deletion lib/importsToResolve.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ function importsToResolve(request) {
// - The exact file name must match (no auto-resolving of '_'-modules).

// Keep in mind: ext can also be something like '.datepicker' when the true extension is omitted and the filename contains a dot.
// @see https://github.com/jtangelder/sass-loader/issues/167
// @see https://github.com/webpack-contrib/sass-loader/issues/167
const ext = path.extname(request);
const basename = path.basename(request);
const dirname = path.dirname(request);
Expand Down
4 changes: 2 additions & 2 deletions lib/loader.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ function sassLoader(content) {
}

if (isSync) {
throw new Error("Synchronous compilation is not supported anymore. See https://github.com/jtangelder/sass-loader/issues/333");
throw new Error("Synchronous compilation is not supported anymore. See https://github.com/webpack-contrib/sass-loader/issues/333");
}

this.cacheable();
Expand Down Expand Up @@ -64,7 +64,7 @@ function sassLoader(content) {
result.map.sources[0] = path.relative(process.cwd(), resourcePath);
// node-sass returns POSIX paths, that's why we need to transform them back to native paths.
// This fixes an error on windows where the source-map module cannot resolve the source maps.
// @see https://github.com/jtangelder/sass-loader/issues/366#issuecomment-279460722
// @see https://github.com/webpack-contrib/sass-loader/issues/366#issuecomment-279460722
result.map.sourceRoot = path.normalize(result.map.sourceRoot);
result.map.sources = result.map.sources.map(path.normalize);
} else {
Expand Down
13 changes: 10 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"test-source-map": "webpack-dev-server --config test/sourceMap/webpack.config.js --content-base ./test/sourceMap --inline",
"test-watch": "webpack --config test/watch/webpack.config.js",
"test-extract-text": "webpack --config test/extractText/webpack.config.js",
"test-hmr": "webpack-dev-server --config test/hmr/webpack.config.js --content-base ./test/hmr --hot --inline"
"test-hmr": "webpack-dev-server --config test/hmr/webpack.config.js --content-base ./test/hmr --hot --inline",
"coverage": "nyc --reporter=lcov npm test"
},
"keywords": [
"sass",
Expand All @@ -22,7 +23,7 @@
],
"repository": {
"type": "git",
"url": "git://github.com/jtangelder/sass-loader.git"
"url": "git://github.com/webpack-contrib/sass-loader.git"
},
"author": "J. Tangelder",
"license": "MIT",
Expand All @@ -46,11 +47,17 @@
"file-loader": "^0.10.0",
"mocha": "^3.0.2",
"node-sass": "^4.5.0",
"nyc": "^10.1.2",
"raw-loader": "^0.5.1",
"should": "^11.2.0",
"style-loader": "^0.13.1",
"webpack": "^2.2.1",
"webpack-dev-server": "^2.4.1",
"webpack-merge": "^3.0.0"
}
},
"files": [
"lib",
"README",
"LICENSE"
]
}

0 comments on commit 84bae1a

Please sign in to comment.