Answer the question
In order to leave comments, you need to log in
How to write @yield('style') in default layout?
An interesting question, Laravel 8 has default.blade.php - as a standard layout.
Pages/home.blade.php is also written with the following content:
@section('metricks')
@foreach($metricks as $metrick)
{{$metrick->value}}
@endforeach
@endsection
@yield()
- then everything is displayed in <body>
<head>
this section?
Answer the question
In order to leave comments, you need to log in
There are no default blades in laravel8. Absolutely not. So you installed additional packages. Breeze? ui? jetstream? This is just to understand. At the same time, 8ka already uses a component approach at the core.
To draw a conclusion in the head - nothing prevents you from scoring it directly. It makes sense to produce sections if it is about metrics.
Right in default.blade.php and output the loop.
If you really want to make it a section, then in default.blade.php
<head>
...
@yield('metrics')
@extends ('default')
@section ('metricks')
...
@endsection
Learn Perl to junior - I would recommend to anyone who works with scripting languages - Perl is very convenient to parse data, and in itself it is very simple, so it will not take much time.
Sometimes simple things are easier to write in perl and run than to write them in python/php. But actually the question of whether to go deep or not can be solved later, when you master the pearl at a minimum level by writing a couple of parsers / utilities.
That is, it is better to learn pearls professionally already in practice, if there is work related to pearls.
if you want to break your brain - better Lisp or Haskell, more productive with even more vacancies than Perl
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question