Skip to content

Commit

Permalink
docs(README): add option types && links (#303)
Browse files Browse the repository at this point in the history
  • Loading branch information
michael-ciniawsky committed Oct 14, 2017
1 parent 58e9996 commit d39b84e
Showing 1 changed file with 18 additions and 13 deletions.
31 changes: 18 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ npm i -D postcss-loader

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

### `Config`
### `Configuration`

**postcss.config.js**
```js
Expand Down Expand Up @@ -108,15 +108,15 @@ module.exports = {

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

|Name|Default|Description|
|:--:|:-----:|:----------|
|`exec`|`undefined`|Enable PostCSS Parser support in `CSS-in-JS`|
|`parser`|`undefined`|Set PostCSS Parser|
|`syntax`|`undefined`|Set PostCSS Syntax|
|`stringifier`|`undefined`|Set PostCSS Stringifier|
|`config`|`undefined`|Set `postcss.config.js` config path && `ctx`|
|`plugins`|`[]`|Set PostCSS Plugins|
|`sourceMap`|`false`|Enable Source Maps|
|Name|Type|Default|Description|
|:--:|:--:|:-----:|:----------|
|[`exec`](#exec)|`{Boolean}`|`undefined`|Enable PostCSS Parser support in `CSS-in-JS`|
|[`parser`](#syntaxes)|`{String\|Object}`|`undefined`|Set PostCSS Parser|
|[`syntax`](#syntaxes)|`{String\|Object}`|`undefined`|Set PostCSS Syntax|
|[`stringifier`](#syntaxes)|`{String\|Object}`|`undefined`|Set PostCSS Stringifier|
|[`config`](#config)|`{Object}`|`undefined`|Set `postcss.config.js` config path && `ctx`|
|[`plugins`](#plugins)|`{Array\|Function}`|`[]`|Set PostCSS Plugins|
|[`sourceMap`](#sourceMap)|`{String\|Boolean}`|`false`|Enable Source Maps|

### `Exec`

Expand All @@ -135,6 +135,11 @@ If you use JS styles without the [`postcss-js`][postcss-js] parser, add the `exe

### `Config`

|Name|Type|Default|Description|
|:--:|:--:|:-----:|:----------|
|[`path`](#path)|`{String}`|`undefined`|PostCSS Config Path|
|[`context`](#context)|`{Object}`|`undefined`|PostCSS Config Context|

#### `Path`

You can manually specify the path to search for your config (`postcss.config.js`) with the `config.path` option. This is needed if you store your config in a separate e.g `./config || ./.config` folder.
Expand Down Expand Up @@ -216,9 +221,9 @@ module.exports = ({ file, options, env }) => ({

|Name|Type|Default|Description|
|:--:|:--:|:-----:|:----------|
|`syntax`|`{String\|Function}`|`undefined`|Custom PostCSS Syntax|
|`parser`|`{String\|Function}`|`undefined`|Custom PostCSS Parser|
|`stringifier`|`{String\|Function}`|`undefined`|Custom PostCSS Stringifier|
|[`parser`](#parser)|`{String\|Function}`|`undefined`|Custom PostCSS Parser|
|[`syntax`](#syntax)|`{String\|Function}`|`undefined`|Custom PostCSS Syntax|
|[`stringifier`](#stringifier)|`{String\|Function}`|`undefined`|Custom PostCSS Stringifier|

#### `Parser`

Expand Down

0 comments on commit d39b84e

Please sign in to comment.