Setting up react project with classes

I just followed the tik-tac-toe game tutorial from the React docs (https://reactjs.org/tutorial/tutorial.html) and noticed that we were using classes, but when I use the npx create-react-app my-app it makes a projects with functions. Is there a way to make a new react project based off of classes or do I have to change those manually?
Tutorial: Intro to React – React
A JavaScript library for building user interfaces
7 Replies
b1mind
b1mind3y ago
Use their new beta docs And try Vite soon as you can CRA is blah
★𝖕𝖆𝖓𝖉𝖆☆
👍 ill try those out thank you! not sure if i missed it, but i didnt see anything that answers my question in there
b1mind
b1mind3y ago
Are you learning React or you actually want to use classes? React hooks are the new recommended way It's just JS
★𝖕𝖆𝖓𝖉𝖆☆
im learning react, the tutorial i followed used the classes to develop their components (not sure of the correct name) instead of functions
class Board extends React.Component
class Board extends React.Component
b1mind
b1mind3y ago
Right and I'm telling you should probably learn the current way It's functions with hooks
b1mind
b1mind3y ago
React Docs Beta
A JavaScript library for building user interfaces
b1mind
b1mind3y ago
This is one the reasons I didn't learn React.... So convoluted...
Want results from more Discord servers?
Add your server