Are SPAs (Single Page Applications) suitable for sites aimed for mobiles?

前端 未结 8 1382
野趣味
野趣味 2021-01-31 03:27

I am planning to create a website with around different 20 views/pages primary for mobile phones.

If I want to focus on a making the user experience very responsive (as

8条回答
  •  北荒
    北荒 (楼主)
    2021-01-31 03:41

    The accepted answer is very good and I agree with it, the latest applications I have developed were mostly made using SPA.

    But I would add that SPA is not the magic solution for all applications, especially when talking about "Critical Path Rendering".


    A brief history

    To achieve a fast "time to first tweet" the processing of an entire framework such as AngularJS might be a problem.

    We realized that it would be harder to achieve what the customer wanted by using Angular. So we built the application without it. The application made extensive use of AJAX requests and other practices of optimization. In the end, the time for rendering the main page decreased by almost 1 second. In two months after the deploy, the customer showed an increase of 30% in sales! Ok, it was an application with simple features and had not the whole richness that a SPA usually have.


    Again, I'm not saying that the problem is with SPA, but I think it is not definetly the end answer for all mobile applications.

提交回复
热议问题