i was learning react and this was the first file that i had started with
in that i tried entering another div and tried with <>
import React, { Component } from 'react';
import logo from './logo.svg';
import './App.css';
class App extends Component {
render() {
return (
<>
<h1>this is me</h1>
<div className="App">
<div className="App-header">
<img src={logo} className="App-logo" alt="logo" />
<h2>Welcome to React</h2>
</div>
<p className="App-intro">
To get started, edit <code>src/App.js</code> and save to reload.
</p>
</div>
</>
);
}
}
this was the code that i had
but the moment i used<> it became an error
rror in ./src/App.js
Syntax error: Unexpected token (7:7)
5 | render() {
6 | return (
> 7 | <>
| ^
8 | <h1>this is me</h1>
9 | <div className="App">
10 | <div className="E
what should i do to get rid of this?