Reputation: 399
I am just starting to develop an application with Laravel and Vue.js
Currently I have it setup so that Laravel acts like a backend API, while Vue.js renders all of the front-end views. All working well and I am getting the hang of working with a SPA.
One thing I am struggling with. When I was using only Laravel, I was getting the Whoops error handling screen if the were any exceptions being generated on the PHP's end. However since switching over to a SPA, I no longer see the exceptions being thrown (I feel like it something to do with Laravel running on the server, but Vue in the browser, clarification would be amazing though...).
I tried searching the internet for ways to make this happen, most suggested using something like Clockwork or Debugbar. However I don't know if that actually fits the requirements I want.
Whoops was beneficial that it let me see the source of the issue, so I could investigation further, and for someone still learning this was great.
Are there any standard processes that are typically adopted to get the above result? Or is there something I am missing, and as a result I am going about it the wrong way (perhaps there is a reason the exceptions don't get thrown the same way).
Any advice would be really appreciated.
Upvotes: 0
Views: 411
Reputation: 794
You can use the "network tab" within the browsers developer tools (available in chrome (CTRL + SHIFT + I), firefox, edge etc.) and investigate the detailed response of the request. It is not as pretty as the actual Woops screen (since it heavily relies on JS and nice css formatting) but it usually meets your requirement of being able to track down the actual source of the issue.
Example of chrome dev tool network tab
Upvotes: 1