how integrate an existing vuejs app created with vue-cli into a laravel project - laravel

I've a vuejs app builded with the latest vue-cli, the vuejs app runs ok with the development server and communicates with the laravel app, but now I'd prefer that laravel handle this static files...if I build the js files with yarn run build this generates me several files, I could add thems to my laravel homepage but I'm afraid that if in the future I make some change and build these files again, I could get different file names...
what is the best approach for this???...I've found several articles integrating vuejs and laravel but all these are using the vuejs tool incorporated with laravel
thanks so much guys

Related

Is it possible to use create-react-app with laravel 7.x

I've been using create-react-app for quite a while and I recently need to build a backend via laravel. Is it possible to use create-react-app, it's npm run start development workflows, etc to communicate with a laravel backend?
I can see that laravel already has a package.json file and from what I can tell, the react packages do not use create-react-app. I have seen an npm package, but it doesn't appear to be current and is probably not compatible with Laravel 7.x.
That's not needed if you are going to build the SPA and the backend in the same directory structure because laravel has its own workflow using Laravel Mix and you can take advantage of the framework Scaffolding but if you are planning to only connect to an existent Laravel Backend you can create your react app with create-react-app command and connect to laravel using axios,fetch or something like that

How do I deploy Vuejs App backed by Laravel, In similar fashion we usually deploy laravel app or I need seperate frontend and backend instances?

Hello guys I have been deploying Laravel applications on the server for a while, I have just created a SPA(Single Page App) Laravel + Vuejs how do I deploy it ? Just like normal laravel app or I need separate Frontend(Vuejs) and Backend (Laravel) instances ?
It is same as regular laravel app deployment.
run npm run production and after that make whole project as zip and put it on serve and just follow the steps as regular laravel project.

Integrate Vue.js with laravel

I have built my static design using vue.js. Now, I need to integrate it within Laravel.
Once I do integrate Laravel with Vue then Laravel is not getting the Design files path. I mean the various Style and JS files.
FYI, I build the Vue in static design and it was working fine before integration with Laravel. But, while integrating with Laravel I am no longer using the build or build.js file. Instead of this, I am building using Laravel ways.
The main issue is the design is broken and the route is not working.

Connecting VueJS with laravel

Me and my co-worker both are freshers and I'm doing the front-end using VueJS and he is doing back-end using Laravel.
But How do we connect both back-end and front-end to deploy the final product?
We are struggling to put VueJS project files inside the laravel project files.
We don't have idea where to put main.js, where to put routers.js store.js App.vue inside the laravel
Install Vue Js inside Laravel Project using npm,Then in your resource/assets foleder you will see the app.js, vue component. Then compile it, laravel mix will place your app.js file inside public/js/app.js. Then include it in view file.
I asked this question when I start my career as a junior software engineer. Now I saw this again randomly. We had no idea how to connect back-end and the front-end. But eventually we learned we are developing a restAPI so we host back-end and front-end separately as two projects and connect them using the restAPI. Back-end and the front-end was two identical projects. =)

Need help deploying Vue Laravel SPA in a shared hosting

I finished developing a Single Page Application using Vue Js in the front end to consume the APIs that I built with Laravel in the backend
I already deployed an old Laravel-only App in my shared hosting but now with all the new js files and node modules I have no idea what to do
I can't find any good tutorial or article, your help will be so much appreciated!
ps: I am using webpack to mix my SPA files

Resources