Download the PHP package yu-laravel/page-speed without Composer

On this page you can find all versions of the php package yu-laravel/page-speed. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package page-speed

Page Speed

Live Demo

A Livewire tool for Laravel that checks a page's speed and Core Web Vitals through the Google PageSpeed Insights API. It runs Lighthouse for a phone and a computer at the same time, turns the scores into a plain-language checklist, and lists the issues that would save the most loading time.

🔗 Live example: yu.net.ua/en/tools/page-speed

What it checks

9 checks in three groups. The result is a score out of 100 and a verdict.

Group Checks
Performance Lighthouse performance on a phone and on a computer
Core Web Vitals (phone) LCP (main content appears), CLS (layout shifts), INP / TBT (reaction to taps), TTFB (server response)
SEO, accessibility, best practices The other Lighthouse scores of the phone run

Requirements

Installation

This also installs yu-laravel/web-tools-core. Both service providers are discovered automatically.

Get an API key in Google Cloud Console (APIs & Services → Credentials, with the PageSpeed Insights API enabled) and add it to .env:

Without a key, the tool stays unavailable.

Usage

Put the component on a page whose layout includes @livewireStyles and @livewireScripts:

Import the styles into your CSS build:

To match your site's colours and fonts, override the --wt-* variables (see Web Tools Core).

Configuration

Env variable Default Description
PAGE_SPEED_ENABLED true Turn the tool off without uninstalling it.
PAGESPEED_API_KEY Google PageSpeed Insights API key.
PAGE_SPEED_PER_HOUR 10 Checks per visitor IP per hour.

One Lighthouse run takes 15–40 seconds, so the API timeout is 75 seconds. Lighthouse results vary from run to run, so a report is cached for 10 minutes and a repeated check shows the same numbers. config/page-speed.php also sets how many Lighthouse issues to show (8).

Events

Languages

13 translations: cs, de, en, es, fr, it, ja, nl, pl, pt, tr, uk and zh. The language is taken from the visitor's browser, with your app locale as the fallback.

Author

Yuriy Akishin:

License

MIT. See LICENSE.


All versions of page-speed with dependencies

PHP Build Version
Package Version
Requires php Version ^8.4
laravel/framework Version ^13.0
livewire/livewire Version ^4.0
yu-laravel/web-tools-core Version ^1.0.2
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package yu-laravel/page-speed contains the following files

Loading the files please wait ...