ideas
ideas copied to clipboard
how to check @stack(variable) is isset or not in laravel blade (Feature Request)
we are having
@push('variable')
contents
@endpush
and will call the same using
@stack('variable')
how to check that stack is isset or not and if not isset allow pushing some content like @yield
Hi there, sorry if I misunderstand what you are asking. Are you asking to push the content only if it doesn't already exist? Would @once
do what you are looking for? https://laravel.com/docs/master/blade#the-once-directive