import * as dayjs from 'dayjs'
Cannot call a namespace ('dayjs')
, TypeError: dayjs__namespace is not a function
try another
const dayjs = require('dayjs')
ReferenceError: require is not defined
How can I do?
I am using dayjs in my typescript project like below
import dayjs from 'dayjs';
:
this.date = params.get('date') ? dayjs().format('DD/MM/YYYY') : '';