2016-08-18 8 views

答えて

13

はチートシートです:

サポートされるスタイルは、各コンポーネントの公式ドキュメントです。

注のスタイルの上に ...ここViewTextコンポーネント用のリンクですテキストでは、Viewがサポートする(ほとんどの)スタイルもサポートされています。

+1

それは、常にそこに電子ではありません。 g。 [TouchableHighlight](https://facebook.github.io/react-native/docs/touchablehighlight.html#style)は空です。 –

4

私は、反応するネイティブログから有効なスタイルのリストを抽出しました。

以下のコレクションは定期的に仕事をしてくれます。

[ 
    "alignContent", 
    "alignItems", 
    "alignSelf", 
    "aspectRatio", 
    "backfaceVisibility", 
    "backgroundColor", 
    "borderBottomColor", 
    "borderBottomLeftRadius", 
    "borderBottomRightRadius", 
    "borderBottomWidth", 
    "borderColor", 
    "borderLeftColor", 
    "borderLeftWidth", 
    "borderRadius", 
    "borderRightColor", 
    "borderRightWidth", 
    "borderStyle", 
    "borderTopColor", 
    "borderTopLeftRadius", 
    "borderTopRightRadius", 
    "borderTopWidth", 
    "borderWidth", 
    "bottom", 
    "color", 
    "decomposedMatrix", 
    "direction", 
    "display", 
    "elevation", 
    "flex", 
    "flexBasis", 
    "flexDirection", 
    "flexGrow", 
    "flexShrink", 
    "flexWrap", 
    "fontFamily", 
    "fontSize", 
    "fontStyle", 
    "fontVariant", 
    "fontWeight", 
    "height", 
    "includeFontPadding", 
    "justifyContent", 
    "left", 
    "letterSpacing", 
    "lineHeight", 
    "margin", 
    "marginBottom", 
    "marginHorizontal", 
    "marginLeft", 
    "marginRight", 
    "marginTop", 
    "marginVertical", 
    "maxHeight", 
    "maxWidth", 
    "minHeight", 
    "minWidth", 
    "opacity", 
    "overflow", 
    "overlayColor", 
    "padding", 
    "paddingBottom", 
    "paddingHorizontal", 
    "paddingLeft", 
    "paddingRight", 
    "paddingTop", 
    "paddingVertical", 
    "position", 
    "resizeMode", 
    "right", 
    "rotation", 
    "scaleX", 
    "scaleY", 
    "shadowColor", 
    "shadowOffset", 
    "shadowOpacity", 
    "shadowRadius", 
    "textAlign", 
    "textAlignVertical", 
    "textDecorationColor", 
    "textDecorationLine", 
    "textDecorationStyle", 
    "textShadowColor", 
    "textShadowOffset", 
    "textShadowRadius", 
    "tintColor", 
    "top", 
    "transform", 
    "transformMatrix", 
    "translateX", 
    "translateY", 
    "width", 
    "writingDirection", 
    "zIndex" 
] 

実装の詳細はここにある: https://github.com/vhpoet/react-native-styling-cheat-sheet/blob/master/README.md

+0

-1;このリストがどこから来たのかは明らかではありません(正しかったと確信することさえできません)。将来のリリースでそれを更新する方法は示されていません。また、初心者には間違いがあります。異なるスタイルルールが異なるコンポーネントに適用されます。 –

+0

@ MarkAmeryログからリストを取得したことを明確に述べているので、誰もがこれらの有効なスタイルプロパティを見つけることができます。 ルールセットは https://github.com/vhpoet/react-native-styling-cheat-sheet/blob/master/README.md – Ahsanwarsi

+0

*ログは何ですか?たぶん私は何かを見逃しているかもしれませんが、私はあなたが何を意味するか分かりません。 –

関連する問題