<!-- Stored in resources/views/child.blade.php -->
@extends('layouts.app')
@section('title', 'Page Title')
@section('sidebar')
@parent
<p>This is appended to the master sidebar.</p>
@endsection@section('content')
<p>This is my body content.</p>
@endsection
I see it like this, use extend to extend your layout, for example you have your css and scripts and csrf tokens and your header that will be pulled into every page.
Use section where you would like to import a section of code to a page,
for example.
you have your main layout layout and on all of your other pages you will extend this main layout
and then you will have a section that you can include in on this page something like a sidebar.