UNPKG

@yash101/schwab-api-client

Version:

A TypeScript client library for interacting with the Charles Schwab Brokerage APIs.

21 lines 663 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.toISO8601 = toISO8601; exports.fromISO8601 = fromISO8601; /** * Converts a Date object to an ISO-8601 string (yyyy-MM-dd'T'HH:mm:ss.SSSZ). * @param date - The Date object to convert. * @returns The ISO-8601 formatted string. */ function toISO8601(date) { return date.toISOString(); } /** * Converts an ISO-8601 string (yyyy-MM-dd'T'HH:mm:ss.SSSZ) to a Date object. * @param isoString - The ISO-8601 formatted string. * @returns The corresponding Date object. */ function fromISO8601(isoString) { return new Date(isoString); } //# sourceMappingURL=TimeUtil.js.map