PHPackages                             kapitancho/walnut-lang-demos - 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. kapitancho/walnut-lang-demos

ActiveLibrary

kapitancho/walnut-lang-demos
============================

0.0.7(2y ago)02SquirrelPHP &gt;=8.2

Since Feb 29Pushed 2y ago1 watchersCompare

[ Source](https://github.com/kapitancho/walnut-lang-demos)[ Packagist](https://packagist.org/packages/kapitancho/walnut-lang-demos)[ RSS](/packages/kapitancho-walnut-lang-demos/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (7)Dependencies (2)Versions (8)Used By (0)

Walnut Lang demos
=================

[](#walnut-lang-demos)

A set of a bit chaotic but extensive examples of the Walnut language.

Installation
------------

[](#installation)

To install the latest version, use the following command:

```
$ composer require kapitancho/walnut-lang-demos
```

Usage
-----

[](#usage)

Provided that the code is served by a Server supporting PHP files, open public/index.php in a browser, explore the code and see the execution results.

### Use with Docker

[](#use-with-docker)

To run the demos in a Docker container, use the following commands:

```
$ docker compose build
$ docker compose up -d
```

Then open  in a browser.

### Introduction to Walnut-Lang

[](#introduction-to-walnut-lang)

- [Custom types](http://localhost:8068/public/?src=lang-type-system&autoexec=1)
- [Casts, hydration, JSON](http://localhost:8068/public/?src=lang-cast-hydrate-json&autoexec=1)

### Some notable demos

[](#some-notable-demos)

- [Fibonacci](http://localhost:8068/public/?src=cast35&autoexec=1)
- [Fizz Buzz - 3 versions](http://localhost:8068/public/?src=cast211&autoexec=1)
- [Books in a Library](http://localhost:8068/public/?src=cast34&autoexec=1)
- [Hydration](http://localhost:8068/public/?src=cast27&autoexec=1)
- [Members model](http://localhost:8068/public/?src=cast37&autoexec=1)
- [Using a database](http://localhost:8068/public/?src=cast23&autoexec=1)
- [Interface-like casts](http://localhost:8068/public/?src=cast14&autoexec=1)
- [JSON](http://localhost:8068/public/?src=cast12&autoexec=1)
- [Subtypes](http://localhost:8068/public/?src=cast11&autoexec=1)

### Methods showcases

[](#methods-showcases)

- [String methods showcase](http://localhost:8068/public/?src=demo-string&autoexec=1)
- [Integer methods showcase](http://localhost:8068/public/?src=demo-integer&autoexec=1)
- [Real methods showcase](http://localhost:8068/public/?src=demo-real&autoexec=1)
- [Array methods showcase](http://localhost:8068/public/?src=demo-array&autoexec=1)
- [Map methods showcase](http://localhost:8068/public/?src=demo-map&autoexec=1)
- [Mutable methods showcase](http://localhost:8068/public/?src=demo-mutable&autoexec=1)
- [Type methods showcase](http://localhost:8068/public/?src=demo-type&autoexec=1)
- [Boolean methods showcase](http://localhost:8068/public/?src=demo-boolean&autoexec=1)

###  Health Score

21

—

LowBetter than 19% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity2

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity49

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~7 days

Total

7

Last Release

763d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/12d2910601119ce65c373b7e21ffc647154bde10c5ad0a0598ab1143aa851701?d=identicon)[kapitancho](/maintainers/kapitancho)

---

Top Contributors

[![kapitancho](https://avatars.githubusercontent.com/u/792682?v=4)](https://github.com/kapitancho "kapitancho (13 commits)")

### Embed Badge

![Health badge](/badges/kapitancho-walnut-lang-demos/health.svg)

```
[![Health](https://phpackages.com/badges/kapitancho-walnut-lang-demos/health.svg)](https://phpackages.com/packages/kapitancho-walnut-lang-demos)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
