Fullstack React

Thể loại: Java Script ;Lập trình
Tác giả : Anthony Accomazzo
  • Lượt đọc : 500
  • Kích thước : 4.80 MB
  • Số trang : 825
  • Đăng lúc : 3 năm trước
  • Số lượt tải : 239
  • Số lượt xem : 2.361
  • Đọc trên điện thoại :
Web development is often seen as a crazy world where the way you develop software is by throwing hacks on top of hacks. I believe that React breaks from this pattern and instead has been designed from first principle which gives you a solid foundation to build on.
A major source of bugs for front-end applications was around synchronizing the data model with the DOM. It is very hard to make sure that whenever data changes, everything in the UI is updated with it.
React’s first innovation was to introduce a pure- JavaScript representation of the DOM and implement diffing in userland and then use events which send simple commands: create, update, delete.
With React, by conceptually re-rendering everything whenever anything changes, not only do you have code that is safe by default, it is also less work as you only need to write the creation path: updates are taken care of for you.
Browsers have, for a long time, been incompatible in
various ways due to the large API surface area of what
they have to support to make the DOM work. Not only
does React provide a great way to solve browser differences, but it enables use cases that were never before possible for a front-end library, such as server-side rendering and the ability to implement rendering targets like native iOS, Android, and even hardware components.
But the most important thing about React and the main reason why you should read this book: not only will you use it to make great applications for your users, it will also make you a better developer. Libraries come and go all the time and React is likely going to be no exception. What makes it special is that it teaches you concepts that can be reused throughout your entire career.
You will become better at JavaScript because React doesn’t come with a templating system. Instead, React pushes you to use the full power of JavaScript to build your user interface.
You are going to practice using parts of functional programming with map and filter and also encouraged to use the latest features of JavaScript (including ES6). By not abstracting away data management, React will force you to think about how to architect your app and encourage you to consider concepts like immutability.