JSX is not JavaScript. It introduces new syntax to JavaScript as sugar for React’s underlying JavaScript APIs. JSX is problematic—to me, at least—for several reasons. It requires,
- An extra compilation step
- Specialized support in your IDE
- Some mind bending in the fuzzy areas that aren’t quite JavaScript and aren’t quite HTML, for example, the awful
<>
tag - Lock-in to Facebook’s view of the web
The creatively named react-helper
library, provides a humane API for creating DOM elements using React that abstracts away React altogether. It’s possible to interoperate with React components, but for pure DOM manipulation, the API does not leak the underlying React implementation.