Skip to content

Commit 8a0afe4

Browse files
committed
lint code
1 parent 281a724 commit 8a0afe4

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

demo/app.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,9 @@ export default class App extends Component {
5454
});
5555
let content = null;
5656
if (_.isArray(this.state.content)) {
57-
content = this.state.content.map(file => {
58-
return <DiffView key={file.filename} source={file.patch}/>;
59-
});
57+
content = this.state.content.map(file =>
58+
<DiffView key={file.filename} source={file.patch}/>
59+
);
6060
} else {
6161
content = <DiffView source={this.state.content}/>;
6262
}

src/chunk.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ import Change from './change';
33
import style from './style';
44

55
export default function Chunk(props) {
6-
const changes = props.changes.map((change, i) => {
7-
return <Change key={i} {...change} lang={props.lang}/>;
8-
});
6+
const changes = props.changes.map((change, i) =>
7+
<Change key={i} {...change} lang={props.lang}/>
8+
);
99
return (
1010
<tbody>
1111
<tr className={style.chunk}>

src/diffview.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ function Part(props) {
1212
const ext = extname(fileName);
1313
const langs = languages(ext);
1414

15-
const items = chunks.map((chunk, i) => {
16-
return <Chunk key={i} {...chunk} lang={langs[0]}/>;
17-
});
15+
const items = chunks.map((chunk, i) =>
16+
<Chunk key={i} {...chunk} lang={langs[0]}/>
17+
);
1818

1919
return (
2020
<article className={style.diff}>

0 commit comments

Comments
 (0)