Skip to content

Commit

Permalink
Merge pull request #162 from d3viant0ne/d3viant0ne-UpdateDocsForFinal
Browse files Browse the repository at this point in the history
chore(readme): Update to webpack standard format
  • Loading branch information
joshwiens committed Jan 20, 2017
2 parents 5a1a0f8 + 700dd55 commit cb3c0b6
Showing 1 changed file with 55 additions and 6 deletions.
61 changes: 55 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,25 @@
# style loader for webpack
[![npm][npm]][npm-url]
[![node][node]][node-url]
[![deps][deps]][deps-url]
[![chat][chat]][chat-url]

<div align="center">
<a href="https://github.com/webpack/webpack">
<img width="200" height="200"
src="https://webpack.js.org/assets/icon-square-big.svg">
</a>
<h1>Style Loader</h1>
</div>

Adds CSS to the DOM by injecting a `<style>` tag

## Install
<h2 align="center">Install</h2>

```
npm install style-loader --save-dev
```

## Usage
<h2 align="center">Usage</h2>

[Documentation: Using loaders](http://webpack.github.io/docs/using-loaders.html)

Expand Down Expand Up @@ -61,7 +72,7 @@ By default, the style-loader appends `<style>` elements to the end of the `<head

If defined, the style-loader will re-use a single `<style>` element, instead of adding/removing individual elements for each required module. **Note:** this option is on by default in IE9, which has strict limitations on the number of style tags allowed on a page. You can enable or disable it with the singleton query parameter (`?singleton` or `?-singleton`).

## Recommended configuration
### Recommended configuration

By convention the reference-counted API should be bound to `.useable.css` and the simple API to `.css` (similar to other file types, i.e. `.useable.less` and `.less`).

Expand Down Expand Up @@ -97,6 +108,44 @@ So the recommended configuration for webpack is:

**Note** about source maps support and assets referenced with `url`: when style loader is used with ?sourceMap option, the CSS modules will be generated as `Blob`s, so relative paths don't work (they would be relative to `chrome:blob` or `chrome:devtools`). In order for assets to maintain correct paths setting `output.publicPath` property of webpack configuration must be set, so that absolute paths are generated.

## License
<h2 align="center">Contributing</h2>

MIT (http://www.opensource.org/licenses/mit-license.php)
Don't hesitate to create a pull request. Every contribution is appreciated. In development you can start the tests by calling `npm test`.

<h2 align="center">Maintainers</h2>

<table>
<tbody>
<tr>
<td align="center">
<img width="150 height="150"
src="https://avatars.githubusercontent.com/sokra?v=3">
<br />
<a href="https://github.com/">Tobias Koppers</a>
</td>
<td align="center">
<img width="150 height="150"
src="https://avatars.githubusercontent.com/SpaceK33z?v=3">
<br />
<a href="https://github.com/">Kees Kluskens</a>
</td>
<tr>
<tbody>
</table>


<h2 align="center">LICENSE</h2>

#### [MIT](./LICENSE)

[npm]: https://img.shields.io/npm/v/style-loader.svg
[npm-url]: https://npmjs.com/package/style-loader

[node]: https://img.shields.io/node/v/style-loader.svg
[node-url]: https://nodejs.org

[deps]: https://david-dm.org/webpack/style-loader.svg
[deps-url]: https://david-dm.org/webpack/file-loader

[chat]: https://badges.gitter.im/webpack/webpack.svg
[chat-url]: https://gitter.im/webpack/webpack

0 comments on commit cb3c0b6

Please sign in to comment.