Skip to content

Commit

Permalink
Merge branch 'fix-reduce-docs' into patch-1
Browse files Browse the repository at this point in the history
  • Loading branch information
Tankunpeng committed Mar 24, 2019
2 parents 53eb60b + a8a3c00 commit 5c49aeb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs/api/ReactWrapper/reduce.md
Expand Up @@ -36,8 +36,8 @@ function Foo() {

```jsx
const wrapper = mount(<Foo />);
const total = wrapper.find(Bar).reduce((amount, n) => amount + n.prop('amount'));
expect(total).to.equal(16);
const total = wrapper.find(Bar).reduce((amount, n) => amount + n.prop('amount'), 0);
expect(total).to.equal(14);
```


Expand Down
4 changes: 2 additions & 2 deletions docs/api/ReactWrapper/reduceRight.md
Expand Up @@ -36,8 +36,8 @@ function Foo() {

```jsx
const wrapper = mount(<Foo />);
const total = wrapper.find(Bar).reduceRight((amount, n) => amount + n.prop('amount'));
expect(total).to.equal(16);
const total = wrapper.find(Bar).reduceRight((amount, n) => amount + n.prop('amount'), 0);
expect(total).to.equal(14);
```


Expand Down

0 comments on commit 5c49aeb

Please sign in to comment.