Why do I love Vue js and Quasar so much?
Why do I love Vue js and Quasar so much?
Vue js is a great little javascript framework that has been an absolute game-changer in all my web projects.
When I started to use Vue js there was something I was not too happy about, and it was the way files and folders had to be organised in my apps. I organised everything one way, then noticed a friend has the folders in another way and so on.
This is when I started to look for another framework built with a pre-organised Vue and Vuex setup.
Quasar V1 is exactly what I was looking for. A clever framework that comes pre-organised with Vue and Vuex which has the power to run your app on multiple hardware including windows, Android, IOS and the web.
Imagine having to build a Vue app from scratch, create your folders, re-add the router, setup Vuex each time. Waste of time….and this when Quasar becomes very handy. A few commands and your app is ready to be worked on. Another command and your apps are compiled to run on Cordova, it is just magical!
On top of all of the above goodies, Quasar also comes with UI components which helps you create stunning forms, tables and other great utilities.
What is the ultimate solution for me when it comes to Vue js and a back end communication?
To get your Vue js app going, you will need a strong back end, I recommend the Laravel API.
Should you build the Vue app inside Laravel or as a separate app?
Based on my experience, building the Vue js app outside Laravel is a much better idea because you can export your whole codebase inside quasar and reuse it to compile apps on different hardware.
For example, I install Laravel on www.api.mydomain.com and the Vue js app on www.mydomain.com.
Right after this setup, I add the Laravel Passport to the API and get a token sent to the Vue js app upon login. I then add an Axios interceptor between the requests and responses that checks for the token. If the token is expired, a new token is fetched via Laravel.
This workflow is great and I just love it. Laravel helps you make your API secure, strong and clean as it comes with so many helpers.
Something very important when using Vue js is to only import the modules, functions you need when using large libraries like moment.js or Lodash. If you import the whole library functions in your apps, be ready to get a bad score on the Google page speed checker.
Overall, Vue js is fantastic, light, fast and easy to learn. Things become a bit more complicated when using Quasar and Laravel. If you are building your app using Cordova, be ready to get a few issues along the way as you have to set up an emulator, SDK libraries, JDK and so on. To use Cordova properly, you will need time to gain some experience.
Laravel is powerful but also takes time to learn. In fact, after 1.5 year of using it, I still haven’t used all of its features due to the constant new updates coming from the community.
Hope this short article will help you decide on whether or not you should use Vue js, Quasar V1 and Laravel for your next project.
Disclaimer:
As an Amazon Associate I earn from qualifying purchases. This post may contain affiliate links which means I may receive a commission for purchases made through links.