IsSameOrBefore
IsSameOrBefore fügt die .isSameOrBefore()
-API hinzu. Diese API gibt einen Boolean
-Wert zurück, der prüft, ob ein Datum mit einem anderen Datum identisch ist oder vor diesem liegt.
javascript
var isSameOrBefore = require('dayjs/plugin/isSameOrBefore');
// import isSameOrBefore from 'dayjs/plugin/isSameOrBefore' // ES 2015
dayjs.extend(isSameOrBefore);
dayjs('2010-10-20').isSameOrBefore('2010-10-19', 'year');