Web concepts Flashcards
(71 cards)
What status codes means?
100s
100s - Informational
What status codes means?
200s
200s - Success
What status codes means?
300s
300s - Redirection
What status codes means?
400s
400s - Client error
What status codes means?
500s
500s - Server error
What is the View Transition API?
A modern web API that enables smooth, animated transitions between different states or pages in web applications.
What is the main benefit of using the View Transition API?
It creates visually engaging transitions that enhance user experience by reducing perceived load times and maintaining context during navigation.
Where can you use the View Transition API?
You can use it in both single-page applications (SPAs) and multi-page applications (MPAs).
What is a same-document view transition?
A transition that animates DOM changes within a single page, typically used in SPAs.
What is a cross-document view transition?
A transition that animates navigation between different pages, typically used in MPAs.
How does the View Transition API work at a high level?
It captures snapshots of the current and new page states, overlays them, and animates the transition using CSS.
What function triggers a view transition in JavaScript?
document.startViewTransition()
What happens when document.startViewTransition() is called?
The browser takes a screenshot of the current state, applies DOM changes, takes another screenshot, and animates between them.
How is the default cross-fade animation achieved in the View Transition API?
The old view fades out (opacity 1 to 0) and the new view fades in (opacity 0 to 1) using CSS animations.
How can you customize the animation of a view transition?
By styling the ::view-transition pseudo-elements with CSS.
What is the purpose of view-transition-name in CSS?
It tags specific elements so they can be animated individually during a transition.
What is the structure of the pseudo-elements used during a view transition?
::view-transition > ::view-transition-group(root) > ::view-transition-image-pair(root) > ::view-transition-old(root) and ::view-transition-new(root)
What does the HTTP status code 200 indicate?
The request has succeeded.
What does the HTTP status code 404 signify?
The requested resource was not found.
True or False: The status code 500 indicates a server error.
True
Fill in the blank: The HTTP status code ___ means ‘Unauthorized’.
401
Which HTTP status code indicates that the request was successful but no content is returned?
204
What does the status code 301 represent?
Moved Permanently.
What is the meaning of the HTTP status code 403?
Forbidden - the server understands the request but refuses to authorize it.