There are two keywords here β Single Page and Application. Letβs break them down so you understand what they both mean
Application
An application is a piece of software designed to fulfill a particular purpose. They are also called widgets.
By this definition, the components we build so far are applications because each of them is designed for a specific purpose:
- Accordion helps show and hide content
- Tabs helps show and hide content in a different way
- Carousel lets users browse through available images by sliding through them
- Datepicker lets users select a date
- Typeahead helps users complete what they are typing
Websites are also applications because they were designed to provide users with information about something.
Single Page
Single Page here means users can use the entire application on a single page β even if they clicked a link to βanother pageβ.
This can sound confusing, letβs break down what happens.
When a user clicks on a link in a normal website, they get directed to another HTML file. You wait for a while and the page reloads.
A good example is Google.
When you click on a link, you get directed to another HTML file. The page reloads and you see the new page.
In Single Page applications, users do not get directed to a second HTML file when they click a link. They stay on the same HTML file instead. The HTML gets changed with CSS or JavaScript.
One good example is Twitter. Notice the sidebars remain unchanged even though both the URL and the content changed.
The simplest SPAs can be created with pure CSS.
More complex SPAs require you understand how to use the URL with location and history interfaces.
Welcome! Unfortunately, you donβt have access to this lesson. To get access, please purchase the course or enroll in Magical Dev School.
Unlock this lesson