Download the PHP package aura/asset-bundle without Composer
On this page you can find all versions of the php package aura/asset-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download aura/asset-bundle
More information about aura/asset-bundle
Files in aura/asset-bundle
Package asset-bundle
Short Description Asset management for aura v2
License BSD-2-Clause
Informations about the package asset-bundle
Aura.Asset_Bundle
Asset management for PHP.
Foreword
Requirements
This package requires PHP 5.3 or later. Unlike Aura library packages, this asset package has userland dependencies:
Installation
This asset-bundle is installable and autoloadable via Composer with the following
require
element in your composer.json
file:
"require": {
"aura/asset-bundle": "2.*"
}
Tests
PSR Compliance
This kernel attempts to comply with PSR-1, PSR-2, and PSR-4. If you notice compliance oversights, please send a patch via pull request.
Community
To ask questions, provide feedback, or otherwise communicate with the Aura community, please join our Google Group, follow @auraphp on Twitter, or chat with us on #auraphp on Freenode.
Structure of Package
Assume you have a Vendor.Package
. All your assets should be in the
web
folder. The folder names css
, images
, js
can be according to your preffered name.
Assuming you have the same structure, now in your template you can point
to /asset/vendor/package/css/some.css
, /asset/vendor/package/js/hello.js
, /asset/vendor/package/images/another.jpg
.
Onething you still need to make sure in the name asset/vendor/package
vendor/package
which is the composer package name.
Usage in any project
Add path to the router, according to the router you are using so that vendor, package and file name can be extracted from it.
An example of usage with Aura.Router and Aura.Dispatcher is given below. The dispacther is used for it need to recursively call the __invoke
method. Else action will return responder, then you need to invoke responder to get the response and finally do send the response.
In your layout or view
Usage in Aura.Web_Kernel
Make sure you have router helper defined for Aura.View.