Skip to content

Commit

Permalink
[Docs] add .length (mistakenly omitted from #1947)
Browse files Browse the repository at this point in the history
  • Loading branch information
ljharb committed Jan 22, 2019
1 parent 4456f39 commit 2a00a00
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
19 changes: 19 additions & 0 deletions docs/api/ReactWrapper/length.md
@@ -0,0 +1,19 @@
# `.length => number`

Returns the number of React nodes enclosed in this wrapper.



#### Returns

`Number`: count of nodes in the list in this wrapper.



#### Example


```jsx
const wrapper = mount(<div />);
expect(wrapper.length).to.equal(1);
```
19 changes: 19 additions & 0 deletions docs/api/ShallowWrapper/length.md
@@ -0,0 +1,19 @@
# `.length => number`

Returns the number of React nodes enclosed in this wrapper.



#### Returns

`Number`: count of nodes in the list in this wrapper.



#### Example


```jsx
const wrapper = shallow(<div />);
expect(wrapper.length).to.equal(1);
```

0 comments on commit 2a00a00

Please sign in to comment.