src/Field/WeekOfYear.php
public static function is53WeekYear(int $year) : bool
    {
        $date = LocalDate::of($year, 1, 1);
        $dayOfWeek = $date->getDayOfWeek();

        return $dayOfWeek->is(DayOfWeek::THURSDAY)
            || ($dayOfWeek->is(DayOfWeek::WEDNESDAY) && $date->isLeapYear());
    }
public static function is53WeekYear(int $year) : bool
    {
        $date = LocalDate::of($year, 1, 1);
        $dayOfWeek = $date->getDayOfWeek();

        return $dayOfWeek->is(DayOfWeek::THURSDAY)
            || ($dayOfWeek->is(DayOfWeek::WEDNESDAY) && $date->isLeapYear());
    }
public static function is53WeekYear ( int $ year ) : bool { $ date = LocalDate :: of ( $ year , 1 , 1 ) ; $ dayOfWeek = $ date -> getDayOfWeek ( ) ; return $ dayOfWeek -> is ( DayOfWeek :: THURSDAY ) || ( $ dayOfWeek -> is ( DayOfWeek :: WEDNESDAY ) && $ date -> isLeapYear ( ) ) ; }
Returns whether the given year has 53 weeks.

A year as 53 weeks if the year starts on a Thursday, or Wednesday in a leap year.

@param int $year The year, validated.

@return bool True if 53 weeks, false if 52 weeks.
Returns whether the given year has 53 weeks .