IT/기타

[Inner Circle] FE과정 2주차 정리

땅일단 2025. 4. 3. 20:58

25/03/31

  • css 선택자 중 특정 속성인 요소를 제외하려면 :not(속성명) 을 붙이면 된다. :not(:disabled) 이나 :not(.submit-btn) 등...
  • 마지막 엘리먼트를 가지고 오려면 HTMLElement.lastElementChild 로 가져온다.

 

25/04/02

  • String.replace("a", ".")는 정규식을 쓰지 않으면 문자열에 포함된 첫 번째 문자열만 바꾼다.
  • 모든 a를 모두 .로 바꾸고 싶다면 String.replaceAll()을 쓰거나 "a" 대신 정규식 /a/g를 사용하자.
  • replaceAll은 ES2021부터 추가된 문법으로, 버전은 tsconfig에서 바꿀 수 있다.

 

25/04/03

멘토님 추천 사이트들

 

변경하기 쉬운 코드

Guidelines for easily modifiable frontend code

frontend-fundamentals.com

 

 

toss frontend-fundamentals · Discussions

Explore the GitHub Discussions forum for toss frontend-fundamentals. Discuss code, ask questions & collaborate with the developer community.

github.com

 

 

Mantine

UI library that you deserve. Mantine has 24 repositories available. Follow their code on GitHub.

github.com

 

 

 

Effect – The best way to build robust apps in TypeScript

Effect is a powerful TypeScript library designed to help developers easily create complex, synchronous, and asynchronous programs.

effect.website

 

 

 

25/04/05

  • mouseup 이벤트는 document 단위에서 하는 것이 좋다. mousedown 이후에 다른곳으로 커서를 옮긴뒤 mouseup을 하면 버그가 일어날 가능성이 높기 때문이다.
  • vscode에서 디버깅 방법: javascript debug terminal 열고 프로젝트 루트에서 npm i 명령어 입력 후 npm run dev 혹은 npm run test