Skip to content

Commit

Permalink
[doc] use require.resolve in examples
Browse files Browse the repository at this point in the history
  • Loading branch information
Simon Mollweide committed Feb 19, 2018
1 parent b43aaf7 commit 7b5d617
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ $ npm install --save-dev eslint eslint-plugin-import @namics/eslint-config
### .eslintrc.js (add globals here if needed)
```
module.exports = {
"extends": "@namics/eslint-config/configurations/es8-browser.js"
"extends": require.resolve("@namics/eslint-config/configurations/es8-browser.js");
};
```

Expand Down
2 changes: 1 addition & 1 deletion documentation/with-flow.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ module.exports = {
"extends": [
"@namics/eslint-config/configurations/es8-react.js",
"@namics/eslint-config/configurations/flow.js"
]
].map(require.resolve)
};
```
9 changes: 6 additions & 3 deletions documentation/with-prettier.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,36 @@
## with prettier

### ES8 (ES2017) + Prettier

```
module.exports = {
"extends": [
"@namics/eslint-config/configurations/es8-browser.js",
"@namics/eslint-config/configurations/es8-browser-disable-styles.js"
]
].map(require.resolve)
};
```

### ES8 (ES2017) + React + Prettier

```
module.exports = {
"extends": [
"@namics/eslint-config/configurations/es8-react.js",
"@namics/eslint-config/configurations/es8-react-disable-styles.js"
]
].map(require.resolve)
};
```

### ES8 (ES2017) + React + Flow + Prettier

```
module.exports = {
"extends": [
"@namics/eslint-config/configurations/es8-react.js",
"@namics/eslint-config/configurations/es8-react-disable-styles.js",
"@namics/eslint-config/configurations/flow.js",
"@namics/eslint-config/configurations/flow-disable-styles.js"
]
].map(require.resolve)
};
```

0 comments on commit 7b5d617

Please sign in to comment.