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
- API token
- next.js css
- typescript react
- Git
- github
- input type=file
- fetch
- react typescript
- getModifierState
- git lab
- 컨디셔널 렌더링
- CSS
- rewrites
- createGlobalStyle
- ngrok실행
- nextjs
- nextjs .env
- github io
- dart 변수
- icon
- react
- react env
- API 토큰
- npm styled-reset
- SCSS
- nextjs 설치
- ngrok설치
- styled components
- bootstrap
- There isn’t anything to compare
Archives
- Today
- Total
꾸준히 성장하는 개발자
[라이브러리] moment cdn, npm 본문
Moment.js | Home
Format Dates moment().format('MMMM Do YYYY, h:mm:ss a'); moment().format('dddd'); moment().format("MMM Do YY"); moment().format('YYYY [escaped] YYYY'); moment().format(); Relative Time moment("20111031", "YYYYMMDD").fromNow(); moment("20120620", "YYYYMMDD"
momentjs.com
moment는 날짜로 연산이 가능하다는 장점이 있다.
사용하는 방법
1. npm 을 이용한 설치
npm install moment
2. CDN 사용
<script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js"></script>
'JavaScript' 카테고리의 다른 글
[JavaScript] 배열에 숫자, 알파벳 등 담아내기 (0) | 2022.05.18 |
---|---|
[라이브러리] chart.js (0) | 2022.05.18 |
[JavaScript] json 파일 받아오기 (0) | 2022.05.12 |
[JavaScript] Local Storage / Session Storage (0) | 2022.04.25 |
[JavaScript] 타이머 함수 , 콜백(Callback) (0) | 2022.04.18 |