interface Factory

Methods

bool
exists(string $view)

Determine if a given view exists.

file(string $path, array $data = [], array $mergeData = [])

Get the evaluated view contents for the given path.

make(string $view, array $data = [], array $mergeData = [])

Get the evaluated view contents for the given view.

mixed
share(array|string $key, mixed $value = null)

Add a piece of shared data to the environment.

array
composer(array|string $views, Closure|string $callback)

Register a view composer event.

array
creator(array|string $views, Closure|string $callback)

Register a view creator event.

$this
addNamespace(string $namespace, string|array $hints)

Add a new namespace to the loader.

$this
replaceNamespace(string $namespace, string|array $hints)

Replace the namespace hints for the given namespace.

Details

at line 13
bool exists(string $view)

Determine if a given view exists.

Parameters

string $view

Return Value

bool

at line 23
View file(string $path, array $data = [], array $mergeData = [])

Get the evaluated view contents for the given path.

Parameters

string $path
array $data
array $mergeData

Return Value

View

at line 33
View make(string $view, array $data = [], array $mergeData = [])

Get the evaluated view contents for the given view.

Parameters

string $view
array $data
array $mergeData

Return Value

View

at line 42
mixed share(array|string $key, mixed $value = null)

Add a piece of shared data to the environment.

Parameters

array|string $key
mixed $value

Return Value

mixed

at line 51
array composer(array|string $views, Closure|string $callback)

Register a view composer event.

Parameters

array|string $views
Closure|string $callback

Return Value

array

at line 60
array creator(array|string $views, Closure|string $callback)

Register a view creator event.

Parameters

array|string $views
Closure|string $callback

Return Value

array

at line 69
$this addNamespace(string $namespace, string|array $hints)

Add a new namespace to the loader.

Parameters

string $namespace
string|array $hints

Return Value

$this

at line 78
$this replaceNamespace(string $namespace, string|array $hints)

Replace the namespace hints for the given namespace.

Parameters

string $namespace
string|array $hints

Return Value

$this