question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Rect with Android Expo project causes blank page

See original GitHub issue

Rect is not working for me in an Expo project on Android.

Works:

<View>
  <Svg height="100" width="100">
    <Circle cx="50" cy="50" r="50" fill="pink" />
  </Svg>
</View>

Does not display:

<View>
  <Svg height="100" width="100">
    <Rect x='15' y='15' width='100' height='100' stroke='red' strokeWidth='2' fill='yellow' />
  </Svg>
</View>

In fact if I include the Rect the navigation header I have in my app doesn’t show. I just get a blank page.

Environment info

Expo SDK Version: 35

Doesn’t work using versions: 9.9.2, 9.9.5, 9.13.3

However it does work using version 8.0.11

This has the knock on effect of stopping react-native-qrcode-svg from working. See https://github.com/awesomejerry/react-native-qrcode-svg/issues/67

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:14

github_iconTop GitHub Comments

4reactions
tmartin1commented, Nov 3, 2019

Had the same problem here, specifying the react-native-svg version to 9.9.2 fixed the issue for me.

3reactions
maxwedwardscommented, Oct 31, 2019

My mistake. Version 9.9.2 does indeed work.

I think I have figured out what is going on. expo install react-native-svg adds ~9.9.2 to your package.json. When yarn installs it grabs the latest minor patch being 9.9.9 which doesn’t work.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Rect with Android Expo project causes blank page · Issue #1175
Rect is not working for me in an Expo project on Android. Works: Does not display:
Read more >
react native expo blank white screen after splash screen
For my issue, I was able to reproduce locally using the above method, and I was missing keyExtractor={(_, id) => id.toString()} in FlatList...
Read more >
Expo React native new EAS build blank white screen ... - Reddit
So my app.js is literrally copied and pasted from the react-navigation website version 6. I get a blank white screen after the splash...
Read more >
Create a Splash Screen - Expo Documentation
The default splash screen is a blank white screen, this can be customized using the splash key in the project's Expo config (app.json,...
Read more >
Troubleshooting | React Navigation
This might occur if you have multiple versions of react-native-safe-area-context installed. If you're using Expo managed workflow, it's likely that you have ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found