PHPackages                             assertchris/laravel-renderless-components - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. assertchris/laravel-renderless-components

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

assertchris/laravel-renderless-components
=========================================

Create components with lazy-evaluated content

1.1.0(5y ago)2026MITPHPPHP ^7.4

Since Jul 20Pushed 5y ago1 watchersCompare

[ Source](https://github.com/assertchris/laravel-renderless-components)[ Packagist](https://packagist.org/packages/assertchris/laravel-renderless-components)[ RSS](/packages/assertchris-laravel-renderless-components/feed)WikiDiscussions main Synced today

READMEChangelog (3)DependenciesVersions (4)Used By (0)

Laravel renderless components
=============================

[](#laravel-renderless-components)

Blade components are great, aren't they? The one thing I was still missing from them is a way to create [renderless components](https://adamwathan.me/renderless-components-in-vuejs). Blade renders top-down, which means you can't lazy-evaluate child content. Imagine being able to define and use a component like this:

```

  @foreach ($items as $item)
  {{ $render($item, $loop->count) }}
  @endforeach

```

```

  {{ $item }} (of {{ $count }})

```

So, I built a way to do it. You need to define your PHP component to look like this:

```
namespace App\View\Components;

use RenderlessComponents\RenderlessComponent;

class List extends RenderlessComponent
{
    public array $items = [];

    public function __construct(array $items)
    {
        $this->items = $items;
    }

    public function view(): string
    {
        return 'components.tailwind-list';
    }

    public function viewParams(): array
    {
        // think of this as the array of params
        // you usually give as the second argument
        // of the view() function
        return [
            'items' => $this->items,
        ];
    }

    public function renderParams(): string
    {
        // think of this as the list of arguments
        // you give to the render function
        return '$params, $count';
    }
}
```

Usage
-----

[](#usage)

Add the library to your project:

```
composer require assertchris/laravel-renderless-components

```

It automatically registers itself, so the only thing left is to extend `RenderlessComponents\RenderlessComponent` instead of `Illuminate\View\Component` and implement the abstract methods.

Caveats
-------

[](#caveats)

- I've changed how the lazy-evaluated content is cached, so that this library works alongside `facade/ignition`. On local (or on any other env, if the file doesn't already exist); the lazy-evaluated content is cached in the `storage/framework/views/components` folder. If your view isn't updating, you might be in an environment other than `local`. You can change the environment or remove the cache files in that folder.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity57

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 ~0 days

Total

3

Last Release

2119d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/00089084814b5b79cd35b9f501bcc48d74c5afb2cb4703562a82e081f31c843c?d=identicon)[assertchris](/maintainers/assertchris)

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/assertchris-laravel-renderless-components/health.svg)

```
[![Health](https://phpackages.com/badges/assertchris-laravel-renderless-components/health.svg)](https://phpackages.com/packages/assertchris-laravel-renderless-components)
```

###  Alternatives

[zservices/query

Pacote para consultas em serviços do governo.

131.1k](/packages/zservices-query)

PHPackages © 2026

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