Low performance in landscape orientation

I have a custom list that automatically descends with animation every n seconds. This is about 600 lines of code, and I think that it does not play any role, so I will not embed it at this time.

The problem is that I have extra low JS-fps (about 0 all the time and about 2 during the animation), and the application crashes after 2-3 minutes of operation, when the application is in landscape mode, but always has> 30 frames per second in the portrait. The landscape mode is the same as the portrait, but with two sliders (I tested one and had 4 frames per second and tested without animation with the same frames) and other measurements of objects. After some time in landscape mode, the following messages appear in the console:

Invalid style with id `316`. Skipping ...
Warning: View: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. 
Warning: View: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop.
Warning: RCTView: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. 

An identifier with an invalid style can change every application launch.

What could it be?

UPD I rewrote one of the elements in the landscape layout and it works fine, but not perfect, but fine. New and old versions had only one difference: styles:

There were many rewritten styles in the old version like this:

<View style={[someStyleClassForVerticalItem, {height: 120, width: 120}]}></View>

And in the new all the properties are built-in:

<View style={{height: 120, width: 120, backgroundColor: '#000'}}></View>

My idea was that this is the reason, but then I started the old version and it works correctly. OH MY GOD. I tried the old version more than 20 times, and in each case I had the same crashes, and now it works.

+4
source share

All Articles