StyleSheet.create() — optimized. Inline — dynamic.
StyleSheet.create():
1const styles = StyleSheet.create({2 container: {3 flex: 1,4 backgroundColor: "#fff"5 },6 text: {7 fontSize: 16,8 color: "#000"9 }10});1112<View style={styles.container}>13 <Text style={styles.text}>Hello</Text>14</View>
Inline styles:
1<View style={{ flex: 1, backgroundColor: color }}>2 <Text style={{ fontSize: size }}>Hello</Text>3</View>
Key differences: