Skip to content

Commit edfd850

Browse files
committed
Update RightCorner.js
Removing styles from constructor
1 parent bc3df34 commit edfd850

File tree

1 file changed

+9
-12
lines changed

1 file changed

+9
-12
lines changed
Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,17 @@
11
import React, { StyleSheet, View } from 'react-native';
22

33
export default class RightCorner extends React.Component {
4-
constructor(props) {
5-
super(props);
6-
this.styles = StyleSheet.create({
7-
button: {
8-
width: 100,
9-
height: 50,
10-
backgroundColor: 'orange',
11-
},
12-
});
13-
}
14-
154
render() {
165
return (
17-
<View style={this.styles.button} />
6+
<View style={styles.button} />
187
);
198
}
209
}
10+
11+
var styles = StyleSheet.create({
12+
button: {
13+
width: 100,
14+
height: 50,
15+
backgroundColor: 'orange',
16+
},
17+
});

0 commit comments

Comments
 (0)