Factory
interface Factory (View source)
Methods
bool
exists(
string $view)
Determine if a given view exists.
file(
string $path,
array $data = array(),
array $mergeData = array())
Get the evaluated view contents for the given path.
make(
string $view,
array $data = array(),
array $mergeData = array())
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
void
addNamespace(
string $namespace,
string|array $hints)
Add a new namespace to the loader.
Details
at line line 23
View
file(
string $path,
array $data = array(),
array $mergeData = array())
Get the evaluated view contents for the given path.
at line line 33
View
make(
string $view,
array $data = array(),
array $mergeData = array())
Get the evaluated view contents for the given view.
at line line 42
mixed
share(
array|string $key,
mixed $value = null)
Add a piece of shared data to the environment.
at line line 52
array
composer(
array|string $views,
Closure|string $callback,
int|null $priority = null)
Register a view composer event.
at line line 61
array
creator(
array|string $views,
Closure|string $callback)
Register a view creator event.
at line line 70
void
addNamespace(
string $namespace,
string|array $hints)
Add a new namespace to the loader.