From 1d858d0e41267cdd7935af99c66bc9df1faa53cd Mon Sep 17 00:00:00 2001 From: Greg Price Date: Mon, 20 Sep 2021 18:36:51 -0700 Subject: [PATCH] react-redux types: Add more $ReadOnly These are all bags of React props, so they should indeed be read-only object types. --- src/react-redux.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/react-redux.js b/src/react-redux.js index d7ad3536917..fd9a84dd77e 100644 --- a/src/react-redux.js +++ b/src/react-redux.js @@ -11,9 +11,8 @@ import type { BoundedDiff } from './generics'; /* eslint-disable flowtype/generic-spacing */ -export type OwnProps<-C, -SP> = $Diff< - BoundedDiff<$Exact>, SP>, - {| dispatch: Dispatch |}, +export type OwnProps<-C, -SP> = $ReadOnly< + $Diff<$ReadOnly>, SP>>, {| dispatch: Dispatch |}>, >; /**