So instead of the traditional model, many websites use JavaScript APIs to request data from the server and update the page content without a page load. This is inefficient and can result in a poor user experience. The trouble with the traditional model here is that we'd have to fetch and load the entire page, even when we only need to update one part of it. But note that most of the page content - including items like the page header, sidebar, and footer - stays the same. When you do this, it needs to update the page with the new set of books to display. It might let you search for a particular genre of book, or might show you recommendations for books you might like, based on books you've previously borrowed. Among other things you could think of a site like this as a user interface to a database. For example, a library website like the Vancouver Public Library. But consider a website that's very data-driven. This model works perfectly well for many sites. If you visit another page, the browser requests the new files, and the server responds with them. The basic model of page loading on the Web is that your browser makes one or more HTTP requests to the server for the files needed to display the page, and the server responds with the requested files. Solve common problems in your JavaScript codeĪ web page consists of an HTML page and (usually) various other files, such as stylesheets, scripts, and images.Express Tutorial Part 7: Deploying to production.Express Tutorial Part 6: Working with forms.
0 Comments
Leave a Reply. |