The components folder in the simple folder structure is incredibly straightforward since it will contain every single component in your entire application. This is a useful folder to have in any size project since almost every project will have multiple custom hooks so having a single place to put them all is really useful. The hooks folder contains every single custom hook in your entire project. Now this is obviously a really simple folder structure but for smaller projects with less than 10-15 components this is honestly not a bad approach. When you first run create-react-app there are no folders inside the src folder and for most people the first 2 folders they create are a components and hooks folder. Outside the src folder your files will be very project dependent so there is no good universal structure to apply since it will depend heavily on your project and the libraries you use. All of these folder structures will only be dealing with the files/folders inside the src folder. Before I jump into the different folder structures I want to mention one thing.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |