OneScript

buttonStyle

Set the native SwiftUI style for buttons.

buttonStyle(value) sets the SwiftUI button style for the current Button or descendant Buttons.

Supported values: automatic, plain, borderless, bordered, and borderedProminent.

import { Button, Modifier, Text, VStack } from "onescript/views"

<VStack modifier={Modifier.buttonStyle("borderedProminent")}>
  <Button action={() => submit()}>
    <Text>Continue</Text>
  </Button>
</VStack>

How is this guide?

Last updated on