bara-react-yofi
TypeScript icon, indicating that this package has built-in type declarations

1.3.58 • Public • Published

bara-react-yofi

Collection of beautiful React components work with Bara cross-platform

Installation

This package was built on top of Bara and React, to use this library you have to install its peer dependencies.

yarn add -E bara bara-react bara-react-yofi

API

SideBar

Dynamic SideBar that can be render in 4 cornor (top, bottom, left, right) of any application.

SideBar also has support to the device orientation.

React Component:

import {SideBar, SideBarItem} from 'bara-react-yofi'

export const MySideBar = () => {
  <SideBar
    horizontal={false}
    horizontalSide="bottom"
    verticalSide="left"
  >
    <SideBarItem name="home" iconMaterial="home" />
    <SideBarItem
      name="settings"
      iconMaterial="settings"
      label="Settings"
    />
  </SideBar>
}

Bara API:

whenSideBarItemPress(name: string)(callback: (...args: any[]) => void):

Bara Trigger to know when a SideBarItem is pressed.

  • Params:
    • name: Which SideBarItem's name

Contribute

Open in Gitpod

License

MIT © BaraJS

Package Sidebar

Install

npm i bara-react-yofi

Weekly Downloads

1

Version

1.3.58

License

MIT

Unpacked Size

46.2 kB

Total Files

45

Last publish

Collaborators

  • nampdn