반응형
    
    
    
  
                              Notice
                              
                          
                        
                          
                          
                            Recent Posts
                            
                        
                          
                          
                            Recent Comments
                            
                        
                          
                          
                            Link
                            
                        
                    | 일 | 월 | 화 | 수 | 목 | 금 | 토 | 
|---|---|---|---|---|---|---|
| 1 | ||||||
| 2 | 3 | 4 | 5 | 6 | 7 | 8 | 
| 9 | 10 | 11 | 12 | 13 | 14 | 15 | 
| 16 | 17 | 18 | 19 | 20 | 21 | 22 | 
| 23 | 24 | 25 | 26 | 27 | 28 | 29 | 
| 30 | 
                            Tags
                            
                        
                          
                          - react #useCallback #react Hook
 - useState #Hooks
 - 플로이드 #c++
 - React-Query
 - React #controlled component #비제어 컴포넌트 #제어 컴포넌트
 - React #리액트 이벤트 주기 #리액트 이벤트
 - axios
 - 백준 #직각삼각형
 - Next.js
 - 백준 #적록색약
 - RateLimit
 - 버블링 #갭쳐링 #이벤트 #JS
 - raect typescript #react #typescript #styled-component
 - npm #not being able to find a file #npm install Error
 - 노마드 코더 #타입스크립트 #typescript #class
 - rate limit
 - React #effect hook #useEffect
 - 빡킹독
 - DP #c++
 - 이친수
 - html entities
 - #useRef #언제 쓰는데?
 - react fragment
 - donwstream #upstream #origin
 - 코드스테이츠 #알고리즘 #그리디
 - React #Hook rules #Hook 규칙
 - JWT #토큰 #refreshToken #accessToken #Token #token #localStorage #sessionStorage
 - interceptors
 - 얕은 복사 #깊은 복사 #shallow copy #deep copy
 - 다익스트라 #파티 #백준
 
                            Archives
                            
                        
                          
                          - Today
 
- Total
 
목록useState #Hooks (1)
꿈꾸는 개발자
리액트 16.8 이전에는 함수형 컴포넌트에서 상태 관리가 불가능했다 => react 16.8에서 Hooks이란 기능이 도입되면서 함수형 컴포넌트에서도 상태 관리가 가능해졌다! (useState도 Hooks 중 하나!) 이벤트 설정: import React from 'react'; function Counter() { const onIncrease = () => { console.log('+1') } const onDecrease = () => { console.log('-1'); } return ( 0 +1 -1 ); } export default Counter; react에선 이벤트를 설정할 때 on이벤트이름={실행하고싶은함수} 형태로 사용해야 한다! => 단 함수호출이 아닌, 함수명만 입력을 해야 한..
        React.js
        
        2023. 1. 21. 16:19