Skip to content

Commit dda3609

Browse files
author
Kent C. Dodds
committed
config prettier
1 parent 945eaac commit dda3609

File tree

2 files changed

+23
-6
lines changed

2 files changed

+23
-6
lines changed

.prettierrc

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"arrowParens": "avoid",
3+
"bracketSpacing": false,
4+
"htmlWhitespaceSensitivity": "css",
5+
"insertPragma": false,
6+
"jsxBracketSameLine": false,
7+
"jsxSingleQuote": false,
8+
"printWidth": 80,
9+
"proseWrap": "always",
10+
"quoteProps": "as-needed",
11+
"requirePragma": false,
12+
"semi": false,
13+
"singleQuote": true,
14+
"tabWidth": 2,
15+
"trailingComma": "all",
16+
"useTabs": false
17+
}

src/example.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
const username = "freddy";
2-
typeof username === "string";
1+
const username = 'freddy'
2+
typeof username === 'string'
33

4-
if (!("serviceWorker" in navigator)) {
4+
if (!('serviceWorker' in navigator)) {
55
// you have an old browser :-(
66
}
77

8-
const greeting = "hello";
9-
console.log(`${greeting} world!`);
10-
[1, 2, 3].forEach(x => console.log(x));
8+
const greeting = 'hello'
9+
console.log(`${greeting} world!`)
10+
;[1, 2, 3].forEach(x => console.log(x))

0 commit comments

Comments
 (0)