- HTML is the backbone of the web and the code you write should be semantic.
- You can’t do this – – You have to wrap the headings in a containing element – – Because of the necessary containing element, I’ve peeped a lot of code in the last year that when rendered looks like this: – – Because the components that rendered the above HTML…
- We often ignore the generated HTML in favour of the cute component display we get with React Developer Tools.
- One of the features that React 16 gave us was the ability to render an array of components without a containing element.
- But… it doesn’t feel like HTML, and I don’t want to have to put all my elements in an array just to get them to render!
HTML is the backbone of the web and the code you write should be semantic. Writing React is not an excuse to forget this.
Continue reading “React.Fragment and Semantic HTML”