JavaScript helper class
access | public |
---|---|
package | kocuj_internal_lib |
actionAddScripts() : void
access | public |
---|
addDataHelperJs() : void
access | public |
---|
addExceptionJs() : void
access | public |
---|
addHelperJs() : void
access | public |
---|
addLibScript(string $handle, string $urlToDirectory, string $filenameWithoutExt, array $mainLibDeps= array()
, array $deps= array()
, string $localizeVar= ''
, array $localizeData= array()
) : void
access | public |
---|
string
Script handle; prefix will be added automatically
string
URL to script directory; main URL to library will be added automatically
string
Script filename without extension
array
Script dependencies with main scripts from Kocuj Internal Lib - default: empty
array
Script dependencies - default: empty
string
Variable for localization; if empty, there will be no localization - default: empty
array
Localization data; used only if $localizeVar is not empty - default: empty
addLibVendorScript(string $handle, string $urlToDirectory, string $filenameWithoutExt, array $mainLibDeps= array()
, array $deps= array()
, string $localizeVar= ''
, array $localizeData= array()
) : void
access | public |
---|
string
Script handle; prefix will be added automatically
string
URL to script directory; main URL to library will be added automatically
string
Script filename without extension
array
Script dependencies with main scripts from Kocuj Internal Lib - default: empty
array
Script dependencies - default: empty
string
Variable for localization; if empty, there will be no localization - default: empty
array
Localization data; used only if $localizeVar is not empty - default: empty
addScript(string $handle, string $urlToDirectory, string $filenameWithoutExt, array $mainLibDeps= array()
, array $deps= array()
, string $ver= ''
, boolean $inFooter= false
, boolean $useMin= true
, string $localizeVar= ''
, array $localizeData= array()
, boolean $addThrowToLocalizeData= false
) : void
access | public |
---|
string
Script handle
string
URL to script directory
string
Script filename without extension
array
Script dependencies with main scripts from Kocuj Internal Lib - default: empty
array
Script dependencies - default: empty
string
Script version - default: empty
boolean
Show script in footer (true) or in header (false) - default: false
boolean
Use minimized script (true) or standard (false) - default: true
string
Variable for localization; if empty, there will be no localization - default: empty
array
Localization data; used only if $localizeVar is not empty - default: empty
boolean
Add settings "throwErrors" to localization data with value indicated if script should throw errors (true) or does not add anything (false) - default: false
checkScriptDebug() : boolean
access | public |
---|
boolean
JavaScript scripts are in debug mode (true) or not (false)getInstance() : object
access | public |
---|
object
Singleton instancegetMinJsFilename(string $filename) : string
access | public |
---|
string
Filename of script without extension
string
Minified JavaScript script filename if WordPress allows for it__clone() : void
access | private |
---|
__construct() : void
access | private |
---|
addDataHelperJsNow() : void
access | private |
---|
addExceptionJsNow() : void
access | private |
---|
addHelperJsNow() : void
access | private |
---|
$actionExecuted : boolean
false
access | private |
---|
$addJs : array
array()
access | private |
---|
$addedJs : array
array()
access | private |
---|
$instance : object
NULL
access | private |
---|