mirror of
https://github.com/hanzoai/gui.git
synced 2026-10-25 02:31:41 +00:00
36 lines
1.0 KiB
Plaintext
36 lines
1.0 KiB
Plaintext
---
|
|
title: Gui UI
|
|
---
|
|
|
|
<IntroParagraph>
|
|
Gui UI is a complete suite of components that render nicely on both React web and React
|
|
Native and come in both styled and unstyled forms.
|
|
</IntroParagraph>
|
|
|
|
You can install each component separately, or all of them at once with:
|
|
|
|
```bash
|
|
yarn add hanzogui
|
|
```
|
|
|
|
## Setup
|
|
|
|
The package `hanzogui` is a superset of `@hanzogui/core`, so if you've already installed core you can change all the references to `hanzogui`.
|
|
|
|
You'll need to add a provider to the root of your app (unlike core, where that is optional), as it will set up the root portal for components like dialogs and popovers.
|
|
|
|
```tsx
|
|
import { createGui, GuiProvider, View } from '@hanzo/gui'
|
|
import { defaultConfig } from '@hanzogui/config/v5' // for quick config install this
|
|
|
|
const config = createGui(defaultConfig)
|
|
|
|
export default () => (
|
|
<GuiProvider config={config}>
|
|
<View />
|
|
</GuiProvider>
|
|
)
|
|
```
|
|
|
|
For a full guide configuration with `createGui`, check [the core configuration docs](/docs/core/configuration).
|