1.所有組件(component)都有一個 style 屬性;
2.在一個地方使用 StyleSheet.Create 去給 style 下定義:
? ? 例:
? ??const styles = StyleSheet.create({
????????????????????????? bigblue: {
? ????????????????????????????????????????? color: 'blue',
? ? ????????????????????????????????????????fontWeight: 'bold',
? ????????????????????????????????????????? fontSize: 30,
????????????????????????????????????????? },
????????????????????????????? red: {
? ? ????????????????????????????????????????color: 'red',????????????????
????????????????????????????????????? },
????????????????????????????????});