Through a support request with a user, we found that they have a custom app logic in a custom route/controller/blade implementation to show an entry, which broke SEO Pro meta because it did not have the proper entry data hydrated through a more typical statamic view.
This PR allows them to manually add their entry content to the cascade like so...
class StoriesController extends Controller
{
public function show(Entry $story)
{
// Add entry content to Statamic's view cascade...
\Statamic\Facades\Cascade::withContent($story);
// Custom app logic
// ...
// Return blade view
return view('stories/story', [...]);
}
Of course this is custom laravel app territory, but that's okay. The user will just need to be mindful about adding their entry content to the cascade in these scenarios where they bypass Statamic's typical route/controller/view flow 👍
Through a support request with a user, we found that they have a custom app logic in a custom route/controller/blade implementation to show an entry, which broke SEO Pro meta because it did not have the proper entry data hydrated through a more typical statamic view.
This PR allows them to manually add their entry content to the cascade like so...
Of course this is custom laravel app territory, but that's okay. The user will just need to be mindful about adding their entry content to the cascade in these scenarios where they bypass Statamic's typical route/controller/view flow 👍