\CGExtensions\jsloaderlibdefn

A class to define a javascript library.

Summary

Methods
Properties
Constants
__construct()
valid()
$name
$callback
$depends
$jsfile
$cssfile
$jsurl
$cssurl
$module
$js_nominify
$css_nominify
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Properties

$name

$name : string

The library name

Type

string

$callback

$callback : callable

An optional callback of the form function($name) to return javascript code. Only one of the jsfile, jsurl, callback, or module properties must be specified.

Type

callable

$depends

$depends : string[]

An array of library names that this library depends upon.

Type

string[]

$jsfile

$jsfile : string

The complete pathname to the javascript file for this library. Only one of the jsfile, jsurl, callback, or module properties must be specified.

Type

string

$cssfile

$cssfile : string

The complete pathname to a css file to associate with this libarary

Type

string

$jsurl

$jsurl : string

A URL to a remote javascript library. Only one of the jsfile, jsurl, callback, or module properties can be specified.

Type

string

$cssurl

$cssurl : string

A complete URL to a remote CSS library.

Type

string

$module

$module : string

The name of a module to query to get javascript code.

Type

string

$js_nominify

$js_nominify : bool

Prevent minifying of the library js code.

Type

bool

$css_nominify

$css_nominify : bool

Prevent minifying of the library css code.

Type

bool

Methods

__construct()

__construct(string $name)

Constructor

Parameters

string $name

The name of the javascript library we are defiing (should not contain spaces or other characters that require encoding)

valid()

valid() : bool

Test if this object is valid.

Returns

bool