refactor: init cypress install & conf

This commit is contained in:
2021-09-02 09:23:46 +00:00
parent eb4a1ca234
commit 51996f9b9c
8418 changed files with 502593 additions and 0 deletions

View File

@@ -0,0 +1,10 @@
import { PluginFunc } from 'dayjs/esm'
declare const plugin: PluginFunc
export = plugin
declare module 'dayjs/esm' {
interface Dayjs {
isoWeeksInYear(): number
}
}

View File

@@ -0,0 +1,15 @@
export default (function (o, c) {
var proto = c.prototype;
proto.isoWeeksInYear = function () {
var isLeapYear = this.isLeapYear();
var last = this.endOf('y');
var day = last.day();
if (day === 4 || isLeapYear && day === 5) {
return 53;
}
return 52;
};
});