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.

alignItems: 'baseline' crashes app

See original GitHub issue

Before filling out an issue, be sure to check the version of react-native-elements you are using and the docs for that version over here.

Explain what you did Aligning Icons to text in a flexDirection: 'row' with alignItems: 'baseline'

Expected behaviour That the icons remain aligned to the baseline together with the text.

Describe the bug Whenever alignItems: 'baseline' is applied as style to the parent view containing Icons. The app crashes.

To Reproduce Reproduced in snack. No need to go nowhere app crashes as soon as opened. To check difference change alignItems: 'baseline'alignItems: 'center'

Possible Solution No idea how this even happens.

Your Environment (please complete the following information):

software version
react-native-elements 1.2.6
react-native 0.61.2
yarn 1.19.1
npm 6.9.0

Issue Analytics

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

github_iconTop GitHub Comments

1reaction
flyingcirclecommented, Jun 13, 2020

I was able to work around this crash by adding flex:1 to the container that had the alignItems:baseline in it. Not sure what’s causing the crash, but hopefully this is a satisfactory answer for anyone running into this.

0reactions
Ahmedhamed77commented, Mar 8, 2022

I have the same issue, any solutions ?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Expo crash once put <Text> inside <View> without error
... once i open that screen the app will crash without error. then i ... remove alignItems: "baseline", from the main view...and its...
Read more >
React native app crash for no reason : r/reactnative - Reddit
when ever I add this line of code in my react native app it crash. when I go to the screen the code...
Read more >
How to simulate "align-items: baseline" in React Native?
Currently React Native supports every Flexbox property except baseline. To get around with this issue, you can set the height to be the...
Read more >
Align Items & Justify Content in React Native - YouTube
Align items is very similar to justifyContent but instead of ... cross axis. baseline Align children of a container along a common baseline....
Read more >
alignment-baseline - SVG: Scalable Vector Graphics | MDN
The alignment-baseline attribute specifies how an object is aligned with respect to its parent. This property specifies which baseline of ...
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