bookmate game
en
Buku
MEHUL MOHAN

Advanced Web Development with React: SSR and PWA with Next.js using React with advanced concepts

  • DDaudalagidmembuat kutipan8 bulan yang lalu
    Virtual DOM is how React maintains a copy of the original DOM the browser shows the end-user, in its own memory.
  • DDaudalagidmembuat kutipan8 bulan yang lalu
    Independent of the internet: Your PWA would be working with something called service workers (more on this later) which enables them to work offline or on low-speed internet connections.
  • DDaudalagidmembuat kutipan8 bulan yang lalu
    A progressive web app is a web app eventually, but a bit better. It uses modern web features to deliver great user experience, similar to the one you’ll experience using a native app.
  • DDaudalagidmembuat kutipan8 bulan yang lalu
    Similarly, if you want to write (update) the redux state, you cannot do it directly. You have to write a reducer for it, that is, something that reduces your state. Once you write a reducer for your store, you can then write dispatchers. These functions are called dispatchers because they dispatch certain actions to these reducers, and these reducers on receiving those actions, update the state accordingly depending on what actions they received.
  • DDaudalagidmembuat kutipan8 bulan yang lalu
    The second parameter, res, is writable by you, the developer. This has methods to call which would, in turn, create an HTTP response under the hood which the API endpoint is supposed to send back to the client.
  • DDaudalagidmembuat kutipan8 bulan yang lalu
    The first parameter, req, contains all the relevant information about the current request hitting that particular endpoint. This might include the POST body data, authentication cookies, custom headers, and so on.
  • DDaudalagidmembuat kutipan8 bulan yang lalu
    Next.js is a framework for building server-side applications with React. A framework provides a lot of things out of the box. Next.js provides solutions to routing, managing pages, server-side rendering, caching, etc. out of the box and is extremely easy to set up.
  • DDaudalagidmembuat kutipan8 bulan yang lalu
    This chapter aims to introduce you to Next.js, which is a server-side rendering framework built for React.
  • DDaudalagidmembuat kutipan8 bulan yang lalu
    Remember, we discussed back that SSR with React is not a cakewalk;you need to handle a lot of edge cases for it to work for you properly.
  • DDaudalagidmembuat kutipan8 bulan yang lalu
    ReactDOM.hydrate, as the name says, just hydrates the existing layout, it doesn’t create the layout and replaces it in DOM. ReactDOM.hydrate knows that the layout string is coming from the server, so it just needs to sync the client-side JS (i.e. events and listeners) with the coming server-side HTML code.
fb2epub
Seret dan letakkan file Anda (maksimal 5 sekaligus)