I used npm init react-app appname which creates, among other files, App.js. In that file is a function component:
npm init react-app appname
App.js
function App() {