paulmuldoon/laravel-results-summary

A Blade component for displaying a summary of items in a collection

Maintainers

Package info

github.com/paulmuldoon151/laravel-results-summary

pkg:composer/paulmuldoon/laravel-results-summary

Transparency log

Statistics

Installs: 3

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

v1.0.0 2026-07-22 16:46 UTC

This package is auto-updated.

Last update: 2026-07-27 14:54:44 UTC


README

A Blade component for displaying a summary of items in a collection.

Compatibility

Package Version Laravel Version PHP Version
^1.0.0 10.x, 11.x, 12.x, 13.x ^8.2

Installation

composer require paulmuldoon/laravel-results-summary

Usage

Paginated:

<x-results-summary class="text-gray-800 text-sm mb-3 font-bold" :items="$cars" empty="No cars found." :paginated="true" label="car" />
Showing 5 of 24 cars

Non-paginated:

<x-results-summary class="text-gray-800 text-sm mb-3 font-bold" :items="$cars" empty="No cars found." :paginated="false" label="car" />
24 cars

Props

  • :items - takes a collection of items to summarise, example "$cars".
  • empty - the message displayed if the collection is empty, example "No cars found". Default is "No items found."
  • :paginated - set to "true" if you are using a paginator on the collection. Default is "false". Will show for example "Showing 10 out of 25 cars" when this is set to true and "10 cars" if set to false.
  • label - singular noun used to describe the collection being summarised, example "car". This will be pluralised automatically by the component if more than one item is found in the collection.

Attributes

Takes standard HTML attributes such as class, id etc.