2017 © Pedro Peláez
 

library assets-cdn

Easily load your assets from a CDN when on production.

image

amrsoliman/assets-cdn

Easily load your assets from a CDN when on production.

  • Monday, August 15, 2016
  • by AmrSoliman
  • Repository
  • 1 Watchers
  • 2 Stars
  • 1,110 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

assets-cdn

Easily display your Laravel assets through a cdn without having to change a line in your views., (*1)

Installation

Add the following require to your composer.json file:, (*2)

"require": {
    ...
    "amrsoliman/assets-cdn": "1.*"
},
...
"post-install-cmd": [
    ...
    "php artisan assets-cdn:update"
],

Then run composer update, (*3)

Add "AmrSoliman\AssetsCdn\AssetsCdnServiceProvider", to the list of providers in config/app.php., (*4)

Run php artisan vendor:publish, (*5)

Go to file config/assets-cdn.php and configure your CDN. We recommend only enabling it in production., (*6)

Note on the CDN

Any CDN works provided that the following conditions are met:, (*7)

  1. The path on your server is the same as the path on the CDN (i.e. yoursite.com/assets/image.png = the.cdn.net/assets/image.png)
  2. The CDN passes through query strings, so that we can invalidate previous versions of your file when you install a new commit?

The Versions

15/08 2016

dev-master

9999999-dev

Easily load your assets from a CDN when on production.

  Sources   Download

MIT

The Requires

 

by Amr Soliman

laravel s3 cdn assets

15/08 2016

v1.1

1.1.0.0

Easily load your assets from a CDN when on production.

  Sources   Download

MIT

The Requires

 

by Amr Soliman

laravel s3 cdn assets