[Refactor] Profile Page
Refactoring the Profile Page
Here are few practices which we need to ensure while refactoring a file-
- Removing the inline CSS and adding them into a separate CSS file.
- Breaking the page into smaller components and reusing them when needed.
- Adding app the API calls into the actions directory.
- Making sure the code is modular enough.
Looking forward to your contribution :)
Hey ! I have been working on refactoring the profile page and i have refactored it partially, also i have formatted all the files in the project using a prettier script npx prettier --write \"./**/*.{js,jsx,json,css}\" . I just wanted to know that even though you have an error state it is not being used anywhere in the component . So what should i do with that ? Also i have reduced the tab width in .prettierrc to 2 because long files with tab width as 4 were very difficult to navigate.
const [error, setError] = useState(true)
@VB-17 Thank you for your interest in this issue.
I would suggest you to open a separate issue for the same.
Add the prettier script into the package.json file as a script and raise a PR for the same.
For now we can comment out the error state as we may need it in future.
Here are few practices which we need to ensure while refactoring a file-
- Removing the inline CSS and adding them into a separate CSS file.
- Breaking the page into smaller components and reusing them when needed.
- Adding all the API calls into the actions directory.
- Making sure the code is modular enough.
Looking forward to your contribution :) In case you have any blockers, feel free to reach out.