PHPackages                             leafs/ui - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. leafs/ui

ActiveLibrary[Framework](/categories/framework)

leafs/ui
========

Leaf UI is a PHP library for building user interfaces

v0.2.0(3y ago)396294[3 issues](https://github.com/leafsphp/ui/issues)[2 PRs](https://github.com/leafsphp/ui/pulls)MITPHPCI failing

Since Jun 4Pushed 3mo ago4 watchersCompare

[ Source](https://github.com/leafsphp/ui)[ Packagist](https://packagist.org/packages/leafs/ui)[ GitHub Sponsors](https://github.com/leafsphp)[ Fund](https://opencollective.com/leaf)[ RSS](/packages/leafs-ui/feed)WikiDiscussions next Synced 1mo ago

READMEChangelog (6)Dependencies (3)Versions (10)Used By (0)

 [![](https://camo.githubusercontent.com/d98ee5e32c2ff016fdfdac6c42654a908f4cc34b229c7b00caacc5a717455ae8/68747470733a2f2f6c6561667068702e6465762f6c6f676f2d636972636c652e706e67)](https://camo.githubusercontent.com/d98ee5e32c2ff016fdfdac6c42654a908f4cc34b229c7b00caacc5a717455ae8/68747470733a2f2f6c6561667068702e6465762f6c6f676f2d636972636c652e706e67)

Leaf UI \[WIP v0.2.0\]
======================

[](#leaf-ui-wip-v020)

Leaf UI is a PHP library for building user interfaces.

Leaf UI doesn't need a new compiler or any extensive compiling, it's just the same old PHP you write everyday; as such, you can build full scalable Leaf UI powered apps or just sprinkle Leaf UI into your existing HTML/PHP code.

v0.2.0 of Leaf UI is currently in development, it is a complete rewrite of the library that comes with a lot of new features and a new API. Leaf UI v0.2.0 will allow you to build full scalable Leaf UI powered apps, write reactive UIs all in PHP. You can think of it as a PHP version of React.

Installing Leaf UI
------------------

[](#installing-leaf-ui)

Like most PHP libraries, we recommend installing Leaf UI with the [Leaf CLI](https://cli.leafphp.dev):

```
leaf install ui@dev-next
```

Or with [composer](//getcomposer.org). Just open up your console and type:

```
composer require leafs/ui:dev-next
```

After this, you can use all of Leaf UI's methods and components.

View the [documentation here](https://staging.ui.leafphp.dev/)

Building your first Leaf UI
---------------------------

[](#building-your-first-leaf-ui)

Since Leaf UI is modelled after React, everything is a component. You can create your own components and handle your application state in them.

```
