Laravel- Call function of a Model in a blade file

Last Updated: August 29, 2020

You have a category.blade.php blade file and you want to call a function name someFunc() inside the Category model

Here you pass the instance of the model to the view

$model = Category::find(1);

Inside your category.blade.php blade file you can call the function