Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FE 코드피드백 #197

Open
crongro opened this issue Feb 14, 2023 · 0 comments
Open

FE 코드피드백 #197

crongro opened this issue Feb 14, 2023 · 0 comments
Labels
Refactor 프로덕션 코드 리팩토링

Comments

@crongro
Copy link

crongro commented Feb 14, 2023

  • if 문을 !(not) 조건을 먼저 체크해서 return 해버리면 들여쓰기 하나 줄일 수 있어요.
  • 함수 파라미터에 바로 타입을 정의해도 되는데, Type 이나 interface도 사용해보세요.
  • await를 사용하는 방식이면 then을 안쓰면 더 계층적이지 않은 코드를 구현할 수 있어요.
  • ' this.state.profileMode === "following" && new Followlists(profile_contents, {'. 이런 표현은 좀 너무 번잡해 보이는데 다른표현도 고려해서 비교해보세요.
  • TS적용 노력이 보이네요. 컴포넌트/함수가 작은 단위로 여러개 나눠져 있어서 좋네요.
@crongro crongro added the Refactor 프로덕션 코드 리팩토링 label Feb 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Refactor 프로덕션 코드 리팩토링
Projects
None yet
Development

No branches or pull requests

1 participant