What is the best backend framework to use for Vue.js ? Express?

Hi Everyone

What is the best back end framework to use with vue.js?
I am assuming it is express.js with node.js? Please let me know if you think otherwise. I am just trying to figure out what direction to go in.

I am trying to develop shopping carts for restaurants.

Also I see some people using Laravel with Vue.js can anyone explain how that works. I do have more experience with PHP but I am trying to transition to Javascript based programming.

thanks in advance for your advice.

Jon

This category is reserved for posts in english. Please use one of the language-specific categories to ask questions in your language

You can remove this hint if you still intend to post here.
–>

Hi. Which capabilities do you need your backend to have? Laravel has a lot of stuff built in

  • router, page templates
  • ORM / query language / migrations / fakers
  • mail (with queues)

I used it before but I got tired wrestling with the ORM. I know sql really well so it was kind of frustrating. Simple things in the orm was quite easy but things a little more complicated was getting really frustrating. But this is my opinion.

There exists a framework written in Javascript which is modelled after Laravel. https://adonisjs.com/ I tried it an it seems nice but the things that frustrated me in laravel is the same in Adonis.

In my current project I use node - express - mysql2 to write a rest-api for a vue applications and so far its been mostly a smooth ride.

Hi Johandalabecka

thanks for the reply. I am building web apps for restaurants for ordering and for email maketing.

I started out with vanilla php but now want to move over to a javascript based stack since I now see some of the limitations php.

I am now trying to find a good stack that works with mysql however it seems that most of the JS applications work with Mongo DB. I have more experience with with relational databases so it is hard for me to wrap my mind around Mongo.

Can you use Express with Vue? Are you using a cloud service for SQL or do you run it through Node?

I have tried Vue and I really like it but I need to figure out how to use it with a mysql backend.

I appreiciat any help so I don’t have to do a 3 week tutorial on something and then come to find I don’t like it.

Thanks
Jon

Hi

Vuejs is just served as a webpage with some css and JavaScript. For this you don’t need anything special. Then I have written rest-api:s in node with Express and mysql2 package (package to talk to MySQL database). Vue then uses axios (http client package) to make requests to the rest-API.

express or koa2, koa is more simple and clear. u can use SQL or sequelize ORM

There is no “Best”. I use C# / .NET Core. But nearly any language / platform that has web support is completely viable. Vue doesn’t really care about the backend or how you connect to it. You could use Ajax / Websockets or put a middleware like GraphQL in between.

Thanks Keithn

If I use Ajax to talk to a PHP MYSQL database would it still be non blocking and would it still be fast?

Thanks

jon

I don’t think php has non blocking capabilities.

Vue.js allows you to develop frontend independently from backend options.
You are free to choose whatever backend framework which your team feels comfortable with and is alive (still maintained and attractive in the development community)