PHPackages                             davekelly/static-generator - 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. davekelly/static-generator

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

davekelly/static-generator
==========================

Generate static HTML/JSON files from Laravel routes

v0.2.0(11y ago)142124[1 issues](https://github.com/davekelly/static-generator/issues)MITPHPPHP &gt;=5.4.0

Since Aug 20Pushed 6y ago3 watchersCompare

[ Source](https://github.com/davekelly/static-generator)[ Packagist](https://packagist.org/packages/davekelly/static-generator)[ RSS](/packages/davekelly-static-generator/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (2)Versions (4)Used By (0)

Static Generator (Laravel 4.2)
==============================

[](#static-generator-laravel-42)

Generate static HTML or JSON files from Laravel routes.

This was developed for use with small data visualisation-type applications where it is not required to deploy a full PHP app with a database. Instead, a front-end-only version with data held as JSON can be used. I have needed to use HTML-only versions of Laravel apps often enough that this package made sense.

Setup &amp; Usage
-----------------

[](#setup--usage)

### Installation

[](#installation)

- Add `'Davekelly\StaticGenerator\StaticGeneratorServiceProvider',` to the end of the `providers` array in `/app/config/app.php`
- You will need to create a writable directory at `/public/static` - this is where the static files are placed

### Usage

[](#usage)

Usage is through a front-end interface. The package adds a route to `/generate` where you will find this interface.

If you generate a static version of a Route that returns a JSON response, the file will have a `.json` extension, otherwise, it will be `.html`.

- Visit `http://your.domain/generate` to see a list of Routes registered in your application
- Click the button next to the Route you'd like to generate a static file for
- If successful, the `.html` or `.json` file will be stored in `/public/static` - you'll be shown a confirmation message with the location &amp; file-name.

Uses
----

[](#uses)

- [Guzzle](http://guzzlephp.org)
- Front-end bootstrap styling via the [MaxCDN Bootstrap CDN](http://www.bootstrapcdn.com/)

Future To-Do's / Improvements
-----------------------------

[](#future-to-dos--improvements)

- Create an Artisan CLI interface
- Look at filtered routes

Updates
-------

[](#updates)

v0.2 - Creates html nested directories mimicking route structure (e.g. route: `/about/contact` saved to `/static/about/contact/index.html`) - based on idea from [pulkitjalan](https://github.com/pulkitjalan/static-generator/blob/3cb252c846fc00f4b0c862813d8f2f97e7476fa0/src/Davekelly/StaticGenerator/Generator.php)

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity20

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 91.7% 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 ~17 days

Total

3

Last Release

4246d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/e60b8586d161f162f92913d2a6ea1d1198f6ce5c5dc2f4f4d3fab6c2738963c3?d=identicon)[davekelly](/maintainers/davekelly)

---

Top Contributors

[![davekelly](https://avatars.githubusercontent.com/u/109402?v=4)](https://github.com/davekelly "davekelly (11 commits)")[![AppSynergy](https://avatars.githubusercontent.com/u/3657244?v=4)](https://github.com/AppSynergy "AppSynergy (1 commits)")

---

Tags

laravelhtmlstaticfront-end

### Embed Badge

![Health badge](/badges/davekelly-static-generator/health.svg)

```
[![Health](https://phpackages.com/badges/davekelly-static-generator/health.svg)](https://phpackages.com/packages/davekelly-static-generator)
```

###  Alternatives

[stevebauman/location

Retrieve a user's location by their IP Address

1.3k7.6M65](/packages/stevebauman-location)[vinkius-labs/laravel-page-speed

Laravel Page Speed

2.5k5.4k1](/packages/vinkius-labs-laravel-page-speed)[bensampo/laravel-embed

Painless responsive embeds for videos, slideshows and more.

142146.8k](/packages/bensampo-laravel-embed)[glhd/conveyor-belt

14797.0k](/packages/glhd-conveyor-belt)[adrianorosa/laravel-geolocation

Laravel Geo Location package to get details for a given IP Address

6593.3k1](/packages/adrianorosa-laravel-geolocation)[bakame/laravel-domain-parser

Laravel package to integrate PHP Domain parser.

26534.8k4](/packages/bakame-laravel-domain-parser)

PHPackages © 2026

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