Skip to content

Commit 9881dec

Browse files
committed
docs: tweaks
1 parent 038a59d commit 9881dec

2 files changed

Lines changed: 3 additions & 12 deletions

File tree

website/docs/14.x/docs/api/render.mdx

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,6 @@ wrapper?: React.ComponentType<any>,
3434

3535
Wraps the tested component in an additional wrapper component. Use this to create custom render functions for common React Context providers.
3636

37-
#### `createNodeMock` {#create-node-mock}
38-
39-
```ts
40-
createNodeMock?: (element: React.ReactElement) => object,
41-
```
42-
43-
Passes `createNodeMock` to the renderer's `create()` method for custom mock refs. This option is passed through to [Test Renderer](https://github.com/mdjastrzebski/test-renderer).
44-
4537
:::note Text string validation
4638

4739
Test Renderer enforces React Native's requirement that text strings must be rendered within a `<Text>` component. If you render a `string` value under components other than `<Text>` (e.g., under `<View>`), it throws an `Invariant Violation: Text strings must be rendered within a <Text> component` error. This matches React Native's runtime behavior.

website/docs/14.x/docs/guides/llm-guidelines.mdx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,9 @@ Actionable guidelines for writing tests with React Native Testing Library (RNTL)
1010
const result = await render(<Component />, options?);
1111
```
1212
13-
| Option | Description |
14-
| ---------------- | ---------------------------------------------------------------- |
15-
| `wrapper` | React component to wrap the rendered component (e.g., providers) |
16-
| `createNodeMock` | Function to create mock refs |
13+
| Option | Description |
14+
| --------- | ---------------------------------------------------------------- |
15+
| `wrapper` | React component to wrap the rendered component (e.g., providers) |
1716
1817
| Return | Description |
1918
| --------------------- | ------------------------------------------------ |

0 commit comments

Comments
 (0)