I'm trying to biuld an app with L4 and Angular. I'm struggling a bit with routes. I'm using the html5Mode(true) to have nice looking urls. It all works fine as long as I don't reload.
If I reload a page with a url other than /
, L4 takes over and tries to send me to the appropriate page. I don't want that. I'd like all pages to be routed to the homepage where angular can take over.
I found a way to redirect all traffic to the home by using this:
Route::get('{all}', function($uri){
return View::make('home');
})->where('all', '.*');
Only issue is that once I try doing request with angular it sends me back the HTML of the homepage instead of the resource I need.
Any idea how I could solve this problem?
Thanks