Hi, y’all,
I’ve been trying to keep up with Sage 9 development for the inevitable day when it hits a stable release. I’m generally sticking with 8.5.0 for production work for now, but I want to be prepared.
So I’m trying to figure out Blade templates, and since I’m probably not the only one doing so, I thought a general thread might be in order.
For me, one thing stands out:
One of the (in my opinion) great things about get_template_part()
is the $slug, $name
functionality which elegantly falls back to general templates if specific ones aren’t available. Sage 8’s example work with this is inspirational and has done a lot to organize my thoughts while building concise templates.
Does Blade allow for this same kind of graceful fallback? For instance does this line work if content-single-post.blade.php
doesn’t exist (which it doesn’t in the repo) but content-single.blade.php
does? Does it ignore the trailing hyphen automatically?
Thanks as always, and I apologize if this question is hopelessly simple.