title: Error with task: Cannot read property 'measureInWindow' of undefined
body: <p>I am trying to setup an application with @react-navigation.   </p>
  
  <p>I have installed all the required dependencies:</p>
  
  <pre><code>"@react-navigation/bottom-tabs": "^5.4.2",
  "@react-navigation/native": "^5.3.0",
  "@react-navigation/stack": "^5.3.2",
  "react-native-safe-area-context": "^1.0.0",
  react-native-screens": "^2.7.0",
  "@react-native-community/masked-view": "^0.1.10",
  "react-native-reanimated": "^1.8.0",
  "react-native-gesture-handler": "^1.6.1",
  </code></pre>
  
  <p>When launching the application I receive errors regarding 'measureInWindow'. </p>
  
  <p><code>wrapNativeSuper.js:10 Unhandled JS Exception: TypeError: Cannot read property 'measureInWindow' of undefined</code></p>
  
  <p>This would appear to relate to the <code>react-native-safe-area-context</code> per some research but I am unable to figure out why that doesn't work. I have pod installed since adding the libraries and rebuilt the application, but the same error persists. If I remove <code>react-native-safe-area-context</code> then react-navigation will complain it is not added.</p>
  
  <p>This question is related but the answer suggests updating react-navigation and I am on the latest version: <a href="https://stackoverflow.com/questions/61006845/typeerror-cannot-read-property-measureinwindow-of-undefined">TypeError: Cannot read property &#39;measureInWindow&#39; of undefined</a> - This question also mentions <code>react-native-safe-area-view</code> but I believe react-navigation no longer uses this in favour of -safe-area-context. </p>
  
  <p>This issue on react-navigation seems to relate (<a href="https://github.com/react-navigation/react-navigation/issues/7933" rel="nofollow noreferrer">https://github.com/react-navigation/react-navigation/issues/7933</a>) but it suggests react-native-safe-area-view is in use and there is a new version (that is not published?)</p>