Building a VueJS SPA with Laravel


SPA or Single Page Application is a single page web application that loads into a single HTML page. Thanks to dynamic refreshing with JavaScript, no additional pages need to be reloaded or loaded during use. In practice, this means that the user sees all the main content in the browser. When scrolling or switching to other pages, the necessary elements are simply loaded instead of a full reload.
In the work process, the user may think that he has launched not a website, but a desktop application, since it instantly responds to all his actions, without delays and "freezes".
This effect can be achieved using advanced JavaScript frameworks: Angular, React, Ember, Meteor, Knockout.
Examples of dynamic apps: Gmail, Google Maps, Facebook, GitHub, etc.

Benefits
·      High speed - all resources are loaded in one session, and during actions on the page, the data simply changes, which saves time;
·      flexibility and responsiveness of the user interface - because there is only one web page, it is easier to build a rich interface, store session information, manage view states and animations;
·      Simplified development - you can start writing code from the file://URL without using the server, no separate code is needed to render the page on the server-side;
·      Data caching - the application sends just one request, collects data, and after that, it can function offline.

Disadvantages
·      Seo optimization requires solutions in the form of server rendering - due to the fact that content is loaded using AJAX technology, which implies dynamic changes in the content of the page, and stability is important for optimization;
·      load on the browser - because client frameworks are heavy, they take a long time to load;
·      JavaScript support is required - without JS, you cannot fully use the full functionality of the application;
· JavaScript memory leak - Due to poor security, SPA is more prone to attackers and memory leaks.