Build a Monthly Subscription App with Laravel Cashier

Blade Templating

Laravel Blade makes it very easy to use a single layout across all your application. This way you don't have to repeat code in multiple places.

Create three folders:

- views/layouts
- views/pages
- views/partials

For a page to use a certain layout, add the following to the top of the file:

@extends('layouts.app')

To include child views (partials):

@include('partials.header')

To pass in a content section:


// in the layout file
@yield('content')

// in the page file
@section('content')
    i am the content
@endsection