Skip to content

Latest commit

 

History

History
36 lines (32 loc) · 661 Bytes

File metadata and controls

36 lines (32 loc) · 661 Bytes

react-native-app-helpers/HeaderProps

Props to be given to header components.

Usage

import type { HeaderProps } from "react-native-app-helpers";
import { Text } from "react-native";

const example: HeaderProps = {
  leftIcons: [
    {
      icon: ExampleIconA,
      onPress() {
        alert(`You have pressed the left icon.`);
      },
    },
  ]
  rightIcons: [
    {
      icon: ExampleIconB,
      onPress() {
        alert(`You have pressed the first right icon.`);
      },
    },
    {
      icon: ExampleIconC,
      onPress() {
        alert(`You have pressed the second right icon.`);
      },
    },
  ],
  children: "Title",
};