Merge pull request #1011 from Jakobud/feature/templating-docs
Added documentation for the @render() Blade method
This commit is contained in:
commit
5299e32aee
|
@ -69,13 +69,16 @@ #### Echoing function results using Blade:
|
||||||
|
|
||||||
{{ Asset::styles() }}
|
{{ Asset::styles() }}
|
||||||
|
|
||||||
#### Rendering a view:
|
#### Render a view:
|
||||||
|
|
||||||
|
You can use **@include** to render a view into another view. The rendered view will automatically inherit all of the data from the current view.
|
||||||
|
|
||||||
<h1>Profile</hi>
|
<h1>Profile</hi>
|
||||||
|
|
||||||
@include('user.profile')
|
@include('user.profile')
|
||||||
|
|
||||||
> **Note:** When using the **@include** Blade expression, the view will automatically inherit all of the current view data.
|
Similarly, you can use **@render**, which behaves the same as **@include** except the rendered view will **not** inherit the data from the current view.
|
||||||
|
|
||||||
|
@render('admin.list')
|
||||||
|
|
||||||
#### Creating loops using Blade:
|
#### Creating loops using Blade:
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue