dayjs week plugin (fr, en-gb)
const dayjs = require("dayjs")
require('dayjs/locale/fr')
require('dayjs/locale/en-gb')
const weekOfYear = require('dayjs/plugin/weekOfYear')
dayjs.extend(weekOfYear)
console.log(dayjs('2020-12-31').locale('fr').week())
console.log(dayjs('2020-12-31').locale('en-gb').week())
no comments