\Hazaar\View\Helper
Cdnjs
CDNJS view helper

This view helper handles loading any available libraries hosted by CDNJS.

Tags

Since

2.1.2

Summary
Methods Properties Constants
lib
run
url
run
set
No constants
Properties
Static
$cache
$cache
$cache_local
$cache_local
$libraries
$libraries
Methods
getLibraryInfo()
getLibraryInfo($name, $force_reload = false)

Parameters

$name

No description

$force_reload

No description

import()
import()
init()
init($view, $args = Array ( ) )

Parameters

$view\Hazaar\View\Layout

No description

$args

No description

lib()
lib($request)

Parameters

$request

No description

load()
load($name, $version = null, $files = null, $priority = 0) : \Hazaar\Version
Load a library hosted on CDNJS

Tags

Throws

\Exception

Parameters

$namemixed

The name of the library to load

$versionmixed

Optionally specify the version to load. If not specified the latest available version will be used.

$filesmixed

Optionally define the files to load. If not specified, CDNJS profides the name of the file to load. This is restricted to a single file and is not always accurate, hence the option to specify the files.

$prioritymixed

Import priority. The higher this number to soon things will be loaded compared to other libraries being loaded.

Returns

\Hazaar\Version

Returns a Hazaar\Version object detailing the version of the library that was loaded.

run()
run($view)

Parameters

$view

No description

url()
url($name, $version, $path)

Parameters

$name

No description

$version

No description

$path

No description

Inherited
initialise()
initialise($args = null)

Parameters

$args

No description

Inherited
requires()
requires($helper, $args = Array ( ) )

Parameters

$helper

No description

$args

No description

Inherited
run()
run($view)

Parameters

$view

No description

Inherited
set()
set($arg, $value)

Parameters

$arg

No description

$value

No description