# intuitive-flexbox

> Intuitive flexbox components for react

Latest version **1.0.9** (published 2024-04-24) · MIT license · 0 weekly downloads

## Install

```sh
npm install intuitive-flexbox
pnpm add intuitive-flexbox
yarn add intuitive-flexbox
bun add intuitive-flexbox
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.9 |
| Published | 2024-04-24 |
| First published | 2023-03-02 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 1 |
| Unpacked size | 14.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 2 |
| Author | trigramco |
| Maintainers | codigo-fuentes |
| Keywords | react, flex, vbox, hbox |

## Links

- npm: https://www.npmjs.com/package/intuitive-flexbox
- Repository: https://github.com/trigramco/intuitive-flexbox
- Homepage: https://github.com/trigramco/intuitive-flexbox#readme
- Issues: https://github.com/trigramco/intuitive-flexbox/issues
- npm.io page: https://npm.io/package/intuitive-flexbox

## Dependencies (1)

- [react](https://npm.io/package/react.md) ^18.2.0

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 1.0.9 (latest) — 2024-04-24
- 1.0.8 — 2024-04-24
- 1.0.6 — 2023-03-03
- 1.0.5 — 2023-03-03
- 1.0.4 — 2023-03-03
- 1.0.3 — 2023-03-02
- 1.0.2 — 2023-03-02
- 1.0.1 — 2023-03-02
- 1.0.0 — 2023-03-02

## README

# Intuitive Flexbox

## Installation

```bash
   yarn add intuitive-flexbox
```

## Implementation

```typescript
import { HBox, VBox } from "intuitive-flexbox";
export default function HomePage() {
  return (
    <VBox className="h-screen bg-black py-10 text-white">
      <h1 className="mb-2">This is a VBox</h1>
      <HBox className="bg-blue-500 bg-opacity-50 py-2">
        This is an HBox
        <div className="mx-2 bg-red-500 px-2">with</div>
        <div className="mx-2 bg-green-500 px-2">multiple items</div>
      </HBox>
      <HBox className="bg-yellow-500 bg-opacity-50">This another HBox</HBox>
    </VBox>
  );
}
```

## Props

### VBox

| Prop name | Type      | Default value | Description                                 |
| --------- | --------- | ------------- | ------------------------------------------- |
| children  | ReactNode | -             | The content of the component                |
| className | string    | -             | Additional CSS class name(s)                |
| id        | string    | -             | The id attribute of the component           |
| center    | boolean   | false         | Whether to horizontally center the children |
| vcenter   | boolean   | false         | Whether to vertically center the children   |
| hFull     | boolean   | false         | Whether to make the component full width    |

### HBox

| Prop name    | Type                      | Default value | Description                                        |
| ------------ | ------------------------- | ------------- | -------------------------------------------------- |
| children     | `ReactNode`               | -             | The content of the component                       |
| className    | `string`                  | -             | Additional CSS class name(s)                       |
| id           | `string`                  | -             | The id attribute of the component                  |
| wFull        | `boolean`                 | `false`       | Whether to make the component full width           |
| hFull        | `boolean`                 | `false`       | Whether to make the component full height          |
| spaceBetween | `boolean`                 | `false`       | Whether to add space between the children          |
| center       | `boolean`                 | `false`       | Whether to horizontally center the children        |
| vcenter      | `boolean`                 | `false`       | Whether to vertically center the children          |
| style        | `Record<string, unknown>` | -             | Additional inline styles to apply to the component |
| wrap         | `boolean`                 | `false`       | Whether to wrap the children onto multiple lines   |

## Mad Props

  <p>to Theodorus Clarence for this <a href="https://github.com/theodorusclarence/ts-nextjs-tailwind-starter">https://github.com/theodorusclarence/ts-nextjs-tailwind-starter</a></p>

---
_Source: https://npm.io/package/intuitive-flexbox · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
