본문 바로가기
보드게임 긱 추천 게임
Wizard Thumbnail
BoardGameGeek 사이트에서 인기순위 상위 100개 중 랜덤 3개를 보여줍니다.
BGG
귀펀치토끼는 부서지지 않는다.
주소(D)
영웅은 공부 따원 안 한다네/뷰

[Vue] 자주 쓰는 기능

dayjs()

https://day.js.org/docs/en/installation/installation

import dayjs from 'dayjs';

// 현재 날짜
const today = dayjs().format();

// 날짜포맷
const todayFormat = dayjs(today).format('YYYY. MM. DD');

현재 날짜 출력하기

<div v-for="(user, index) in userList" :key="index">
    <div class="text_date">{{ dayjs(user.createDate).format('YYYY. MM. DD') }}</div>
  </div>

HTML에서 Date Format 적용할 때

완료
내 컴퓨터