PHPackages                             backfron/laravel-inline-assets - 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. backfron/laravel-inline-assets

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

backfron/laravel-inline-assets
==============================

Render your javascript and css files inline for better performance in production.

0.1.2(4y ago)080MITPHPPHP ^7.3|^8.0

Since Nov 9Pushed 4y ago1 watchersCompare

[ Source](https://github.com/backfron/laravel-inline-assets)[ Packagist](https://packagist.org/packages/backfron/laravel-inline-assets)[ Docs](https://github.com/backfron/laravel-inline-assets)[ RSS](/packages/backfron-laravel-inline-assets/feed)WikiDiscussions main Synced 3d ago

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

LaravelInlineAssets
===================

[](#laravelinlineassets)

`backfron/laravel-finder` allows you to render your JS and CSS assets inline with the rest of your HTML in production environments. This can improve the load speed of your website reducing the http requests. In fact, I wrote these package in order to improve the results of my webpages in Google [PageSpeed Insights](https://developers.google.com/speed/pagespeed/insights/).

Installation
------------

[](#installation)

Via Composer

```
$ composer require backfron/laravel-inline-assets
```

Usage
-----

[](#usage)

Simply replace the use of `asset()` and `mix()` helpers in your blade files for the directives that this package provides.

```
// Instead of this

// Write this
@inlineAsset('css/app.css')
@inlineAsset('js/app.js')
```

And if you are using the `mix()` helper:

```
// Instead of this

// Write this
@inlineMix('css/app.css')
@inlineMix('js/app.js')
```

The package will automatically creates a link or script tag if you are in non production environment (like local, devlopment, etc.). If you are in production the package gets the file contents and render it inside inline with the HTML using the appropiate tag (`` or ``).

If you want to customize the environments in which the asssets should be rendered inline, just publish the config file.

```
php artisan vendor:publish --tag=laravel-inline-assets.config
```

Next, add the environments that you want inside the *inline* key.

```
return [
    'inline' => [
        'production',
        'pre-production',
        'other-env',
        ... // ANY
        ... // OTHER
        ... // ENVIRONMENT
    ],
];
```

Change log
----------

[](#change-log)

Please see the [changelog](changelog.md) for more information on what has changed recently.

Testing
-------

[](#testing)

```
phpunit
```

Contributing
------------

[](#contributing)

Please see [contributing.md](contributing.md) for details and a todolist.

Security
--------

[](#security)

If you discover any security related issues, please email author email instead of using the issue tracker.

Credits
-------

[](#credits)

- [Jairo Ushiña](https://github.com/backfron)
- [All Contributors](../../contributors)

License
-------

[](#license)

Please see the [license file](license.md) for more information.

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity47

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

Total

3

Last Release

1552d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4fe0ea7207e8118e6e8984b665a5164df0414ceaa0513dacd0555719eec98bf4?d=identicon)[jago86](/maintainers/jago86)

---

Top Contributors

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

---

Tags

laravelLaravelInlineAssets

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/backfron-laravel-inline-assets/health.svg)

```
[![Health](https://phpackages.com/badges/backfron-laravel-inline-assets/health.svg)](https://phpackages.com/packages/backfron-laravel-inline-assets)
```

###  Alternatives

[barryvdh/laravel-ide-helper

Laravel IDE Helper, generates correct PHPDocs for all Facade classes, to improve auto-completion.

14.9k123.0M687](/packages/barryvdh-laravel-ide-helper)[interaction-design-foundation/laravel-geoip

Support for multiple Geographical Location services.

17221.0k3](/packages/interaction-design-foundation-laravel-geoip)[nedwors/navigator

A Laravel package to ease defining navigation menus

433.1k](/packages/nedwors-navigator)[xefi/faker-php-laravel

Faker php integration with laravel

1915.1k](/packages/xefi-faker-php-laravel)[dcblogdev/laravel-junie

Install pre-configured guides for Jetbrains Junie

392.5k](/packages/dcblogdev-laravel-junie)

PHPackages © 2026

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