Skip to content

Commit

Permalink
Extracting prettier config (forem#10847)
Browse files Browse the repository at this point in the history
Co-authored-by: Nick Taylor <[email protected]>
  • Loading branch information
Rafi993 and nickytonline authored Oct 15, 2020
1 parent 54cb0ec commit 906811e
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 10 deletions.
5 changes: 5 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"singleQuote": true,
"trailingComma": "all",
"printWidth": 80
}
8 changes: 3 additions & 5 deletions app/javascript/.storybook/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ const path = require('path');
const marked = require('marked');
const renderer = new marked.Renderer();

const prettierConfig = require('../../../.prettierrc.json');

module.exports = {
stories: ['../**/__stories__/*.stories.jsx'],
addons: [
Expand All @@ -13,11 +15,7 @@ module.exports = {
{
name: '@storybook/addon-storysource',
loaderOptions: {
prettierConfig: {
singleQuote: true,
trailingComma: 'all',
printWidth: 80,
},
prettierConfig,
},
},
],
Expand Down
5 changes: 0 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,6 @@
"svgo --disable=removeViewBox --pretty"
]
},
"prettier": {
"singleQuote": true,
"trailingComma": "all",
"printWidth": 80
},
"repository": {
"type": "git",
"url": "git+https://github.com/thepracticaldev/dev.to.git"
Expand Down

0 comments on commit 906811e

Please sign in to comment.