In this tutorial you will learn about the What Is Single Page Application In Angularjs? and its application with practical example.
What Is Single Page Application In Angularjs?
What Is AngularJS?
AngularJS is one of the widely used front-end web application framework used for building Single Page Application (SPA). It extends the traditional HTML with new attributes and data-binding components that enable us to serve dynamic page content. In Our Next article, we’ll learn how to build a Single Page Application (SPA) using AngularJS Routing and AngularJS Template.
What Are Single Page Application Advantages (Pros)
Building any application as single page application will comes with significant number of benefits. In this article, we will talk about some of the key single page application advantages listed as below –
Improved User Experience :- Single page application bring a much-improved experience to the user.
No Page Refresh :- In a Single Page Application, there is no need to refresh the whole page for every request, all our code (JS, HTML, CSS) is loaded when application loads for the first time. Loading of the dynamic contents and the navigation between pages is done without refreshing the page.
Faster and Responsive :- Single Page Applications are faster because they require less bandwidth, and no full page refreshes when user navigates through the application.
Caching capabilities :- Single Page Applications comes with caching capabilities which allows it to cache any local data effectively. Single Page Application sends single request to server and then stores all the data it receives locally. Which it can use it and work even offline.
What Are Single Page Application Disadvantages (Cons)
While building single page application will comes with significant number of benefits. It also has some disadvantages that must be considered while building a single page application –
Initial load is slow :- All our code (JS, HTML, CSS) is loaded when application loads for the first time which cause it slow initially.
Search Engine Optimization(SEO) :- Single Page Applications are not considered as much seo friendly. Fortunately, Google and Bing started indexing Single Page Applications.