Download the PHP package metrique/laravel-cdnify without Composer

On this page you can find all versions of the php package metrique/laravel-cdnify. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-cdnify

laravel-cdnify

[GitHub release]()

Features

Installation

Set up.

  1. composer require metrique/laravel-cdnify
  2. Optionally add Metrique\CDNify\CDNifyServiceProvider::class to the list of Autoloaded Service Providers in config/app.php.
  3. Optionally add 'CDNify'=>Metrique\CDNify\CDNifyFacade::class to the list of Class Aliases in config/app.php.

CDNify supports Laravel Package Discovery and so steps 2 and 3 are optional.

Config.

Config defaults can be configured by editing config/cdnify.php in your main application directory.

You can publish the config/cdnify.php config file to your application config directory by running php artisan vendor:publish --tag="cdnify-config"

Usage

Examples.

Get Helper

A resource exists in your mix-manifest.json, which has been created by Laravel Mix. <script src="{{ $cdnify->get('js/site.js', true) }}" async></script>

Get the CDN as a string.

$cdnify->cdn();

Set a local path and get the full CDN path.

$cdnify->path('/some/static/resource.jpg')->toString();

CDNify

$cdnify is automatically registered for use in all Laravel views.

$cdnify->defaults(); If environments, mix or roundRobin settings are changed, this will discard the changes in favour of the config settings.

$cdnify->cdn(); Returns a CDN path from the config, if roundRobin is set to true then it will iterate through the list of CDN's on each call.

$cdnify->path($path); Sets the path to be CDNified.

$cdnify->toString(); Returns the CDN and path as a string.

$cdnify->get($path, $params = []); Helper utility combining the path and toString methods. You may pass an array of params (mix, environments, roundRobin) to override the settings once.

$cdnify->environments($environments); Set the environments where the path should be CDNified.

$cdnify->mix($bool); Sets whether mix should be used, if available.

$cdnify->roundRobin($bool); Enables round robin iteration on the cdn list.

CDNify command

php artisan metrique:cdnify This command will run npm run production or gulp --production and then deploy any assets listed in mix-manifest.json to s3 (or other disk), via the Laravel Filesystem.

Options

--build-source[=BUILD-SOURCE] Sets the path to the source files that are to be uploaded. [default: "/build"]

--build-dest[=BUILD-DEST] Sets the path where files are to be uploaded. [default: "/build"].

--disk[=DISK] Set disk/upload method. [default: "s3"]

--force Toggle force upload of files.

--skip-build Skips the running npm run production or gulp --production build process.

--manifest[=MANIFEST] Set manifest location. [default: "/build/mix-manifest.json"]


All versions of laravel-cdnify with dependencies

PHP Build Version
Package Version
Requires laravel/framework Version >=5.5
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package metrique/laravel-cdnify contains the following files

Loading the files please wait ....