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 |
Tags
- TABLESPACE
- react hook
- Debug
- IBM
- react
- codewar
- type
- descendingOrder
- JDBC
- useEffect
- TypeScript
- isSquare
- manifest.json
- DB2
- java api
- custom hook
- codewars
Archives
- Today
- Total
taesik
increase 1 per 1second using closure function 본문
const out = function ():Function {
let cnt=0;
let internal =()=> ++cnt;
return internal;
}
const out2 =out();
setInterval(function(){
console.log(out2())
},1000);
'Concepts > TypeScript' 카테고리의 다른 글
| Count instance in object (0) | 2022.04.06 |
|---|---|
| curring (0) | 2022.01.23 |
| closure 1 - return result of function /return function (0) | 2022.01.23 |
| Utility Type (0) | 2021.12.28 |