Celestine API Documentation - v0.2.0
    Preparing search index...

    Function localToUTC

    • Convert local birth time to UTC.

      Parameters

      • birth: BirthData

        Birth data with local time and timezone

      Returns CalendarDateTime

      UTC datetime

      Handles day rollover when timezone conversion crosses midnight.

      // 18:00 EST (-5) = 23:00 UTC
      const utc = localToUTC({
      year: 2000, month: 1, day: 1,
      hour: 18, minute: 0, second: 0,
      timezone: -5, latitude: 0, longitude: 0
      });
      // { year: 2000, month: 1, day: 1, hour: 23, minute: 0, second: 0 }