Answer the question
In order to leave comments, you need to log in
What is the correct way to include a template in a file?
I'm using Blade Engine.
I have a loop where a template is added to a file using the @include
.
@include('/skills/partials/_progress_bar_success', [
'score' => $skill->score,
'positive' => $task->pivot->positive
])
Answer the question
In order to leave comments, you need to log in
I don't think you should think about the implementation details of @include (this is not a php include), because the template engine is chosen precisely for convenience, while sacrificing slightly performance. If in some task every byte of RAM and a microsecond of processor time is important to you, then do not use the template engine at all.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question