class Assets

A factory class for creating frontend asset compilers.

Properties

array $sources
protected $lessImportOverrides
protected $fileSourceOverrides

Methods

__construct(string $name, Cloud $assetsDir, string|null $cacheDir = null, array|null $lessImportDirs = null, array $customFunctions = [])

No description

js(callable $callback)

No description

css(callable $callback)

No description

localeJs(callable $callback)

No description

localeCss(callable $callback)

No description

jsDirectory(callable $callback)

No description

makeJs()

No description

makeCss()

No description

makeLocaleJs(string $locale)

No description

makeLocaleCss(string $locale)

No description

makeJsCompiler(string $filename)

No description

makeLessCompiler(string $filename)

No description

makeJsDirectoryCompiler(string $string)

No description

string
getName()

No description

void
setName(string $name)

No description

Cloud
getAssetsDir()

No description

void
setAssetsDir(Cloud $assetsDir)

No description

string|null
getCacheDir()

No description

void
setCacheDir(string|null $cacheDir)

No description

array
getLessImportDirs()

No description

void
setLessImportDirs(array $lessImportDirs)

No description

void
addLessImportOverrides(array $lessImportOverrides)

No description

void
addFileSourceOverrides(array $fileSourceOverrides)

No description

Details

__construct(string $name, Cloud $assetsDir, string|null $cacheDir = null, array|null $lessImportDirs = null, array $customFunctions = [])

Parameters

string $name
Cloud $assetsDir
string|null $cacheDir
array|null $lessImportDirs
array $customFunctions

Assets js(callable $callback)

Parameters

callable $callback

Return Value

Assets

Assets css(callable $callback)

Parameters

callable $callback

Return Value

Assets

Assets localeJs(callable $callback)

Parameters

callable $callback

Return Value

Assets

Assets localeCss(callable $callback)

Parameters

callable $callback

Return Value

Assets

Assets jsDirectory(callable $callback)

Parameters

callable $callback

Return Value

Assets

JsCompiler makeJs()

Return Value

JsCompiler

LessCompiler makeCss()

Return Value

LessCompiler

JsCompiler makeLocaleJs(string $locale)

Parameters

string $locale

Return Value

JsCompiler

LessCompiler makeLocaleCss(string $locale)

Parameters

string $locale

Return Value

LessCompiler

JsDirectoryCompiler makeJsDirectory()

Return Value

JsDirectoryCompiler

protected JsCompiler makeJsCompiler(string $filename)

Parameters

string $filename

Return Value

JsCompiler

protected LessCompiler makeLessCompiler(string $filename)

Parameters

string $filename

Return Value

LessCompiler

protected JsDirectoryCompiler makeJsDirectoryCompiler(string $string)

Parameters

string $string

Return Value

JsDirectoryCompiler

string getName()

Return Value

string

void setName(string $name)

Parameters

string $name

Return Value

void

Cloud getAssetsDir()

Return Value

Cloud

void setAssetsDir(Cloud $assetsDir)

Parameters

Cloud $assetsDir

Return Value

void

string|null getCacheDir()

Return Value

string|null

void setCacheDir(string|null $cacheDir)

Parameters

string|null $cacheDir

Return Value

void

array getLessImportDirs()

Return Value

array

void setLessImportDirs(array $lessImportDirs)

Parameters

array $lessImportDirs

Return Value

void

void addLessImportOverrides(array $lessImportOverrides)

Parameters

array $lessImportOverrides

Return Value

void

void addFileSourceOverrides(array $fileSourceOverrides)

Parameters

array $fileSourceOverrides

Return Value

void