Depends what do you need. In my opinion both approaches are valid.
No need to redeploy backend if you changed frontend. Put backend on api.example.com and frontend on example.com.
I am building an app with a Vue front-end and Laravel backend. In terms of code structure I see two options.
create the Vue app in the resources folder for the Laravel project.
Create a separate Vue project for the front-end and the Laravel project would only consist of the back-end code. They would have separate github repositories.
My concern is ongoing code development and deployment. If I make a change to the Vue side, I don't want to redeploy the whole code base to the server. If they are separate applications in separate Git repositories, there is built-in separation where front/back end developers aren't messing with the back/front end. Perhpas I am overthinking this and I'll admit that ongoing deployment isn't my strong suit. Any insight and opinions are welcome.
Please or to participate in this conversation.