PHPackages                             kodeks/smart-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. kodeks/smart-assets

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

kodeks/smart-assets
===================

Smart Asset Management for laravel

1106PHP

Since Aug 6Pushed 11y ago1 watchersCompare

[ Source](https://github.com/Freezko/smart-assets)[ Packagist](https://packagist.org/packages/kodeks/smart-assets)[ RSS](/packages/kodeks-smart-assets/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

smart-assets
============

[](#smart-assets)

Smart Asset Management for laravel

This package add automatic coffee, less...etc convert to js and css. It work when you specify path to file like /pipeline/\*/\*.coffee

\##Installation

Begin by installing this package through Composer. Edit your project's composer.json file to require kodeks/smart-assets.

It might look something like:

```
  "require": {
    "laravel/framework": "4.1.*",
    "kodeks/smart-assets": "dev-master"
  }
```

Next, update Composer from the Terminal:

```
    composer update
```

Once this operation completes, add the service provider. Open `app/config/app.php`, add the following items to the providers array.

```
    'Kodeks\SmartAssets\SmartAssetsServiceProvider',
```

Next optionally, ensure your environment is setup correctly because by default the asset pipeline will cache and and minify assets on a production environment.

Inside `bootstrap/start.php`

```
  $env = $app->detectEnvironment(array(
    'local' => array('your-machine-name'),
  ));
```

Usage
-----

[](#usage)

Place these lines into your Laravel view/layout

```

```

or if you want concatenate files (work when environment is production)

```

```

they save code to vendor.min.css file and replace this strings

Configuration
-------------

[](#configuration)

To create a custom package config for smart-assets run

```
  php artisan config:publish kodeks/smart-assets
```

### routing array

[](#routing-array)

```
  'routing' => array(
    'prefix' => '/pipeline'
  ),
```

This prefix uses when you need convert files

### paths

[](#paths)

```
  'paths' => array(
    'public'
```

These are the directories we search for files in. You can think of this like PATH environment variable on your OS. We search for files in the path order listed below.

### modules

[](#modules)

I you use package \[\], this function may be usefull

```
  'modules' => true
```

if true, when smart-assets find files in "path" and not find, it goes to the public/packages/module/ or app/modules/ when production

### mimes

[](#mimes)

```
  'mimes' => array(
      'javascripts' => array('.js', '.js.coffee', '.coffee', '.html', '.min.js'),
      'stylesheets' => array('.css', '.css.less', '.css.scss', '.less', '.scss', '.min.css'),
  ),
```

In order to know which mime type to send back to the server we need to know if it is a javascript or stylesheet type. If the extension is not found below then we just return a regular download. You should include all extensions in your `filters` here or you will likely experience unexpected behavior. This should allow developers to mix javascript and css files in the same directory.

commands
--------

[](#commands)

if you need flush cashe, use command

```
  php artisan assets:clean
```

They flush /storage/cache and /storage/views/

\#P.S.

The idea, code and documentation belongs to the \[ttps://github.com/CodeSleeve/asset-pipeline\] Thanks guys. Your code is awesome. But i need this functions. Maybe someone else needs this kind of functionality so I'm posting this package

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

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.

### Community

Maintainers

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

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/kodeks-smart-assets/health.svg)

```
[![Health](https://phpackages.com/badges/kodeks-smart-assets/health.svg)](https://phpackages.com/packages/kodeks-smart-assets)
```

###  Alternatives

[voku/portable-ascii

Portable ASCII library - performance optimized (ascii) string functions for php.

574401.5M117](/packages/voku-portable-ascii)[spatie/php-structure-discoverer

Automatically discover structures within your PHP application

17824.5M57](/packages/spatie-php-structure-discoverer)[laminas/laminas-uri

A component that aids in manipulating and validating » Uniform Resource Identifiers (URIs)

3834.9M89](/packages/laminas-laminas-uri)[remipelhate/distil

164.4k](/packages/remipelhate-distil)

PHPackages © 2026

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