import moment from "https://cdn.skypack.dev/moment@2.29.4";

const moment0 = moment('2022-03-31')
console.log('moment0:',moment0.format('YYYY-MM-DD'))

const subMoment = moment0.subtract(1,'month')
console.log('subMoment:',subMoment.format('YYYY-MM-DD'))

const addMoment = moment0.add(1,'month')
console.log('addMoment:',addMoment.format('YYYY-MM-DD'))

const subMoment2 = moment0.subtract(1,'month')
console.log('subMoment2:',subMoment2.format('YYYY-MM-DD'))

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.