我今天刚开始学习 React。如何在 Visual Studio 的终端中的控制台上消除该错误消息。
(node: 9374)Warning: To load an ES module,
set "type": "module" in the package.json or use the .mjs extension.
/Users/nishihaider/workspace-ui/react-todo-app/src/App.js:1
import React from "react";
import "./App.css";
function App() {
<>
return (
<h1>ToDo</h1>
);
</>
}
export default App;