PHPackages                             czim/laravel-localization-route-cache - 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. [Caching](/categories/caching)
4. /
5. czim/laravel-localization-route-cache

AbandonedArchivedLibrary[Caching](/categories/caching)

czim/laravel-localization-route-cache
=====================================

Translated route caching solution for laravel localization

0.9.9(7y ago)48175.1k↑42.1%111MITPHPPHP &gt;=5.5.9

Since Aug 25Pushed 7y agoCompare

[ Source](https://github.com/czim/laravel-localization-route-cache)[ Packagist](https://packagist.org/packages/czim/laravel-localization-route-cache)[ Docs](https://github.com/czim/laravel-localization-route-cache)[ RSS](/packages/czim-laravel-localization-route-cache/feed)WikiDiscussions master Synced today

READMEChangelog (1)Dependencies (4)Versions (12)Used By (1)

Translated Route Caching Solution for Laravel Localization
==========================================================

[](#translated-route-caching-solution-for-laravel-localization)

[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)

**Important**: This solution has been merged into `mcamara/laravel-localization` since version `1.3.11`. This package is no longer required!

A cobbled together fix to allow caching routes per locale for [mcamara's laravel localization](https://github.com/mcamara/laravel-localization).

See the [github issue related to this fix](https://github.com/mcamara/laravel-localization/issues/201) in the original package.

This has been tested with laravel `5.1` through `5.6`.

Version Compatibility
---------------------

[](#version-compatibility)

LaravelPackage5.1.x0.8.x5.2.x and up0.9.xChange log
----------

[](#change-log)

[View the change log](CHANGELOG.md).

Install
-------

[](#install)

Via Composer

```
$ composer require czim/laravel-localization-route-cache
```

If you don't use auto-discovery, add the service provider *after* mcamara's in your `config/app.php`:

```
    Mcamara\LaravelLocalization\LaravelLocalizationServiceProvider::class,
    Czim\LaravelLocalizationRouteCache\LaravelLocalizationServiceProvider::class,
```

In your App's `RouteServiceProvider`, use the `LoadsTranslatedCachedRoutes` trait:

```
class RouteServiceProvider extends ServiceProvider
{
    use \Czim\LaravelLocalizationRouteCache\Traits\LoadsTranslatedCachedRoutes;
```

Usage
-----

[](#usage)

To cache your routes, use

```
    php artisan route:trans:cache
```

instead of the normal `route:cache` command.

To list the routes for a given locale, use

```
    php artisan route:trans:list {locale}

    # for instance:
    php artisan route:trans:list en
```

To clear cached routes for all locales, use

```
    php artisan route:trans:clear
```

Note that using `route:clear` will also effectively unset the cache (at the minor cost of leaving some clutter in your bootstrap/cache directory).

Credits
-------

[](#credits)

- [Coen Zimmerman](https://github.com/czim)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

37

—

LowBetter than 81% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity44

Moderate usage in the ecosystem

Community14

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 75% 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 ~78 days

Total

10

Last Release

2891d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/1657b09521b6030fe32d864a493ded8b1dbbdf737ef3772135dfc123cea34767?d=identicon)[czim](/maintainers/czim)

---

Top Contributors

[![czim](https://avatars.githubusercontent.com/u/11831617?v=4)](https://github.com/czim "czim (9 commits)")[![kkomelin](https://avatars.githubusercontent.com/u/755066?v=4)](https://github.com/kkomelin "kkomelin (3 commits)")

---

Tags

cachingdeprecatedlaravellocalizationlocalizationtranslationscacheroute

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/czim-laravel-localization-route-cache/health.svg)

```
[![Health](https://phpackages.com/badges/czim-laravel-localization-route-cache/health.svg)](https://phpackages.com/packages/czim-laravel-localization-route-cache)
```

###  Alternatives

[psr/simple-cache

Common interfaces for simple caching

8.1k772.9M2.7k](/packages/psr-simple-cache)[psr/cache

Common interface for caching libraries

5.2k726.4M1.7k](/packages/psr-cache)[react/cache

Async, Promise-based cache interface for ReactPHP

445131.2M46](/packages/react-cache)[omaralalwi/lexi-translate

Laravel translation package with morph relationships and caching.

7413.7k5](/packages/omaralalwi-lexi-translate)[maartenstaa/laravel-41-route-caching

This package allows you to cache your routes definitions, thereby speeding up each request.

25381.4k](/packages/maartenstaa-laravel-41-route-caching)[beste/in-memory-cache

A PSR-6 In-Memory cache that can be used as a fallback implementation and/or in tests.

2515.9M12](/packages/beste-in-memory-cache)

PHPackages © 2026

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