2017 © Pedro Peláez
 

library assets

a php helper for static assets.

image

yakuzan/assets

a php helper for static assets.

  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 6 Forks
  • 0 Open issues
  • 6 Versions
  • 0 % Grown

The README.md

Assets is a php helper for working with static assets & embedding.

:package: This package helps you to add toastr.js notifications to your Laravel 5 project., (*1)

Build Status Latest Stable Version Latest Unstable Version Build Status Scrutinizer Code Quality Code Coverage Total Downloads License , (*2)

Install

You can install the package using composer, (*3)

$ composer require yakuzan/assets

alternative instalation :

if you don't want to use composer you can still use assets, just download the file assets.php put in a subfolder and just include it like, (*4)

php include 'path/to/your/subfolder/assets.php';, (*5)

## Usage display jquery link jquery($version = '3.2.1', $src = null), (*6)

php echo jquery(); output => <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>, (*7)

you can overrite the jquery version like this:, (*8)

php echo jquery(2.0); output => <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.0/jquery.min.js"></script>, (*9)

or even a local version of jquery by providing a second parameter, the source of the file : ```php echo jquery(null, 'path/to/jquery.min.js'); output => , (*10)

``` similar function
* fontawesome($version = '4.7.0', $href = null) * bootstrap_js($version = '4.0.0-alpha.6', $src = null) * bootstrap_css($version = '4.0.0-alpha.6', $href = null), (*11)

to include a font-awesome tag very easily just use this helper function : ```php echo icon('edit); // output : , (*12)

echo icon('edit', 'span'); // to switch from 'i' tag to a 'span' // output : ```, (*13)

to insert a image tag it's super easy img($src = null, $attrs = []) ```php echo img('profile.png'); // output : , (*14)

echo img('profile.png', ["class" => "rounded small", "id" => "profile"]);// if you want to add custom attributs // ```, (*15)

similar methods * css($href = '', $attrs = []) * less($href = '', $attrs = []) * js($src = null, $default = '', $attrs = []), (*16)

The Versions

09/02 2018

dev-master

9999999-dev https://github.com/yakuzan/assets

a php helper for static assets.

  Sources   Download

MIT

The Requires

  • php >=5.4

 

The Development Requires

09/02 2018

v0.0.5

0.0.5.0 https://github.com/yakuzan/assets

a php helper for static assets.

  Sources   Download

MIT

The Requires

  • php >=5.4

 

The Development Requires

09/05 2017

v0.0.4

0.0.4.0

a php helper for static assets.

  Sources   Download

MIT

The Requires

  • php >=5.4

 

The Development Requires

09/05 2017

v0.0.3

0.0.3.0

a php helper for static assets.

  Sources   Download

MIT

The Requires

  • php >=5.4

 

The Development Requires

06/05 2017

v0.0.2

0.0.2.0

a php helper for static assets.

  Sources   Download

MIT

The Requires

  • php >=5.6.4

 

The Development Requires

06/05 2017

v0.0.1

0.0.1.0

a php helper for static assets.

  Sources   Download

MIT

The Requires

  • php >=5.6.4

 

The Development Requires