Search code examples
laraveloverridinglaravel-bladevoyager

Voyager navbar padding problem when override


Problem: When I override my voyager view using a custom controller. I am getting a padding problem at the top: problem

Desired output This is how it should be: output

My code browse.blade.php

@extends('voyager::master')

@section('content')

    @foreach($exploitants as $exploitant)
        {{ $exploitant->exp_nom }}<br>
    @endforeach

@endsection>

Solution

  • Don't use <br> inside a loop. It might the one causing the problem. Every browser interpret <br> differently. Try using a fixed px margins instead.

    And change @endsection> to @endsection