Download the PHP package markstory/mini-asset without Composer

On this page you can find all versions of the php package markstory/mini-asset. 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 mini-asset

Mini Asset

Build Status codecov.io Total Downloads

Mini Asset is a small footprint library that provide tools to assist in building an asset minification/optimization pipeline. It uses a simple INI based configuration file that lets you define output files, that are comprised of a number of input files. Input files can be processed by filters on a per-extension or per file basis. Filters allow you to integrate existing pre-processors and minifiers or build your own.

Features

Installing

Add this library to your application with composer, after that you can start integrating MiniAsset into your application and use the provided CLI tools to generate asset targets:

Usage

Before MiniAsset can do anything, you'll need to define a configuration file to define your asset and which filters apply to them. For example purposes, we'll assume you have some CSS files that need to be minified.

Defining a configuration file

In your application's configuration directory create a file called assets.ini. In this file we'll put all the configuration that MiniAsset needs. We'll cover how to use multiple configuration files later on. Assuming your, application has a app.css and reset.css put the following in your config file:

The above also assumes that WEBROOT resolves to your application's document root. In the above we defined a few sections. First, the [css] section defines how all CSS files should behave:

We also defined an [app.css] section. This section defines the files that are used to create WEBROOT/cache_css/app.css when it is generated. We've added two files.

See the sample configuration file for an annotated sample configuration file.

Use the CLI tool to build your asset

With a build target defined, we can now generate our asset. We can use the CLI tool to generate our assets:

The above should generate output indicating that the all.css file we defined was compiled. If we were to re-run the above command all.css would be skipped. MiniAsset is smart enough to know when the components of a build target change and only re-build files when it is necessary.

You can also use the mini_asset CLI tool to clear targets:

PSR7 Middleware

Mini-asset provides a PSR7 middleware adapter that implements the pattern found in zendframework/zend-stratagility and SlimPHP. Before you can use the middleware provided by mini-asset be sure to setup a config file with your assets. Next, integrate mini-asset into your middleware stack. For example in a SlimPHP app you would do:

Framework Integrations

Issues

Please report any issues you have with the plugin to the issue tracker on github.

License

Mini Asset is offered under an MIT license.

Copyright

2010-2018 Mark Story (http://mark-story.com)

Authors

See the github contributors list.

Changelog

See CHANGELOG for changes only available on master. See github releases for changelogs on previous releases.


All versions of mini-asset with dependencies

PHP Build Version
Package Version
Requires php Version >=7.4,<8.4
league/climate Version ~3.0
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 markstory/mini-asset contains the following files

Loading the files please wait ....