Skip to content

Commit

Permalink
Fix formatting with newer Prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
timdorr committed Jan 27, 2019
1 parent 3b06021 commit d32f9fa
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
5 changes: 2 additions & 3 deletions docs/basics/ExampleTodoList.md
Expand Up @@ -77,9 +77,8 @@ const todos = (state = [], action) => {
}
]
case 'TOGGLE_TODO':
return state.map(
todo =>
todo.id === action.id ? { ...todo, completed: !todo.completed } : todo
return state.map(todo =>
todo.id === action.id ? { ...todo, completed: !todo.completed } : todo
)
default:
return state
Expand Down
9 changes: 4 additions & 5 deletions docs/introduction/CoreConcepts.md
Expand Up @@ -50,11 +50,10 @@ function todos(state = [], action) {
case 'ADD_TODO':
return state.concat([{ text: action.text, completed: false }])
case 'TOGGLE_TODO':
return state.map(
(todo, index) =>
action.index === index
? { text: todo.text, completed: !todo.completed }
: todo
return state.map((todo, index) =>
action.index === index
? { text: todo.text, completed: !todo.completed }
: todo
)
default:
return state
Expand Down

0 comments on commit d32f9fa

Please sign in to comment.