官术网_书友最值得收藏!

Chapter 2. JSX in Depth

In the first chapter, we built our first component using React. We saw how using JSX makes the development easy. In this chapter, we will pe deep into JSX.

JavaScript XML (JSX) is an XML syntax that constructs the markup in React components. React works without JSX, but using JSX makes it easy to read and write the React components as well as structure them just like any other HTML element.

In this chapter, we will cover following points:

  • Why JSX?
  • Transforming JSX into JavaScript
  • Specifying HTML tags and React components
  • Multiple components
  • Different types of JSX tags
  • Using JavaScript expressions inside JSX
  • Namespaced components
  • Spread attributes
  • CSS styles and JSX
  • JSX Gotchas

At the end of the chapter, we will get familiar with the JSX syntax, how it should be used with React, and best practices of using it. We will also study some of the corner cases that one can run into while using JSX.

主站蜘蛛池模板: 杭锦旗| 黄山市| 鲜城| 大港区| 永顺县| 江油市| 怀安县| 沁水县| 徐汇区| 平邑县| 贵定县| 石台县| 西昌市| 隆子县| 丘北县| 涪陵区| 威信县| 九寨沟县| 定结县| 海口市| 缙云县| 沽源县| 辰溪县| 法库县| 平顺县| 奉节县| 虹口区| 富川| 合水县| 许昌县| 沛县| 泸水县| 泰顺县| 武城县| 疏附县| 南昌市| 韶山市| 西林县| 科尔| 诏安县| 芒康县|