Skip to content

Commit 4be21cd

Browse files
committed
test: Adjust type tests to be compatible with React 18 typings
1 parent 183162d commit 4be21cd

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

test/typetests/react-redux-types.typetest.tsx

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,12 @@ class App extends Component<any, any> {
9999

100100
const targetEl = document.getElementById('root')
101101

102-
ReactDOM.render(<Provider store={store}>{() => <App />}</Provider>, targetEl)
102+
ReactDOM.render(
103+
<Provider store={store}>
104+
<App />
105+
</Provider>,
106+
targetEl
107+
)
103108

104109
declare var store: Store<TodoState>
105110
class MyRootComponent extends Component<any, any> {}
@@ -125,7 +130,9 @@ declare var todoActionCreators: { [type: string]: (...args: any[]) => any }
125130
declare var counterActionCreators: { [type: string]: (...args: any[]) => any }
126131

127132
ReactDOM.render(
128-
<Provider store={store}>{() => <MyRootComponent />}</Provider>,
133+
<Provider store={store}>
134+
<MyRootComponent />
135+
</Provider>,
129136
document.body
130137
)
131138

0 commit comments

Comments
 (0)