Skip to content

[BUG] style prop does not conform to standard View style prop #80

Description

@dominictobias-bullish

Describe the bug

Minor but the prop and handling of style should be style?: StyleProp<ViewStyle> | undefined

This allows the style to be an array like other RN Views.

We can spread the style into a new object each render but this is less efficient as React caches static styles so style={[staticStyles, { ...dynamicStyles... }] is more efficient than spreading and the static styles don't need to get sent over the JS->Native bridge every time.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomers

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions