{"_id":"zoned-date-time","_rev":"6-fc8afa93a19cf8e1b970c76d11fca940","name":"zoned-date-time","description":"A tiny JavaScript Date with full IANA timezone support","dist-tags":{"latest":"1.1.0"},"versions":{"0.0.3":{"name":"zoned-date-time","version":"0.0.3","description":"A tiny JavaScript Date with full IANA timezone support","main":"src/zoned-date-time.js","files":["dist/","getting_started.js","LICENSE-MIT","README.md","src/"],"repository":{"type":"git","url":"git+ssh://git@github.com/rxaviers/zoned-date-time.git"},"keywords":["date","time","datetime","timezone","zone","metazone","iana"],"author":{"name":"Rafael Xavier de Souza","email":"rxaviers@gmail.com","url":"http://rafael.xavier.blog.br"},"contributors":[{"name":"Ramalingam Kandaswamy Manikandan"}],"license":"MIT","bugs":{"url":"https://github.com/rxaviers/zoned-date-time/issues"},"homepage":"https://github.com/rxaviers/zoned-date-time#readme","scripts":{"test":"eslint --ext .js src && mocha","build":"npm test && mkdir -p dist && rm -f dist/* && echo Building dist/zoned-date-time.js && babel src/zoned-date-time.js -o dist/zoned-date-time.js && echo Done"},"devDependencies":{"babel-cli":"^6.7.7","babel-core":"^6.7.7","babel-eslint":"^6.0.4","babel-preset-es2015":"^6.6.0","chai":"^3.5.0","eslint":"^3.18.0","eslint-config-defaults":"^9.0.0","iana-tz-data":">=2017.1.0","mocha":"^2.4.5"},"gitHead":"6e20e381bcf78acec64598ec9319767b75510870","_id":"zoned-date-time@0.0.3","_shasum":"0e23f0a9f037aee36f08ff9dd016b2e5ba644343","_from":".","_npmVersion":"2.15.11","_nodeVersion":"4.7.3","_npmUser":{"name":"rxaviers","email":"rxaviers@gmail.com"},"dist":{"shasum":"0e23f0a9f037aee36f08ff9dd016b2e5ba644343","tarball":"https://registry.npmjs.org/zoned-date-time/-/zoned-date-time-0.0.3.tgz","integrity":"sha512-UivcuLJmN551EDrtlAGXCEbMJoLQZotBeAQEVVG4czj2nkCxF8JWV9TSKmVaiSBvzlRoLxwsNB35teDpLwCQEw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCd5C60JnQkOAhelvqCQwGfHpBrspXfEbnYNDG3Af7czwIhAJvdRs9YeynzqEMWcRNfG4I2fh+bEo17O0u58fkzx43a"}]},"maintainers":[{"name":"rxaviers","email":"rxaviers@gmail.com"}],"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/zoned-date-time-0.0.3.tgz_1491505525451_0.8009717632085085"},"directories":{}},"0.0.4":{"name":"zoned-date-time","version":"0.0.4","description":"A tiny JavaScript Date with full IANA timezone support","main":"src/zoned-date-time.js","files":["dist/","getting_started.js","LICENSE-MIT","README.md","src/"],"repository":{"type":"git","url":"git+ssh://git@github.com/rxaviers/zoned-date-time.git"},"keywords":["date","time","datetime","timezone","zone","metazone","iana"],"author":{"name":"Rafael Xavier de Souza","email":"rxaviers@gmail.com","url":"http://rafael.xavier.blog.br"},"contributors":[{"name":"Ramalingam Kandaswamy Manikandan"}],"license":"MIT","bugs":{"url":"https://github.com/rxaviers/zoned-date-time/issues"},"homepage":"https://github.com/rxaviers/zoned-date-time#readme","scripts":{"test":"eslint --ext .js src && mocha","build":"npm test && mkdir -p dist && rm -f dist/* && echo Building dist/zoned-date-time.js && babel src/zoned-date-time.js -o dist/zoned-date-time.js && echo Done"},"devDependencies":{"babel-cli":"^6.7.7","babel-core":"^6.7.7","babel-eslint":"^6.0.4","babel-preset-es2015":"^6.6.0","chai":"^3.5.0","eslint":"^3.18.0","eslint-config-defaults":"^9.0.0","iana-tz-data":">=2017.1.0","mocha":"^2.4.5"},"gitHead":"f63422e18a7c8b591ef0ec63b32af30f995f7b33","_id":"zoned-date-time@0.0.4","_shasum":"d5c40701491a50466b96329cea29115ce1cd12dc","_from":".","_npmVersion":"3.9.6","_nodeVersion":"6.9.5","_npmUser":{"name":"rxaviers","email":"rxaviers@gmail.com"},"maintainers":[{"name":"rxaviers","email":"rxaviers@gmail.com"}],"dist":{"shasum":"d5c40701491a50466b96329cea29115ce1cd12dc","tarball":"https://registry.npmjs.org/zoned-date-time/-/zoned-date-time-0.0.4.tgz","integrity":"sha512-KzBdgxTf7vjaoaBtDEPn0vcvFszW9rZxR2NYPeHj4kYpP32Dh1AbzQ+kP1Dp8MTl/rpgpYKsBkfuyR/8Yv6ADA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGXkqJmEwOLIIgdBC7cDz/Wmrt/YsD3gXQIEwcb64+1wAiEA4lpl4768xu2uHXcikD1KH2HJ2zV6jM+xmQtmnLKUjgw="}]},"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/zoned-date-time-0.0.4.tgz_1492281722533_0.9258420919068158"},"directories":{}},"1.0.0":{"name":"zoned-date-time","version":"1.0.0","description":"A tiny JavaScript Date with full IANA timezone support","main":"src/zoned-date-time.js","files":["dist/","getting_started.js","LICENSE-MIT","README.md","src/"],"repository":{"type":"git","url":"git+ssh://git@github.com/rxaviers/zoned-date-time.git"},"keywords":["date","time","datetime","timezone","zone","metazone","iana"],"author":{"name":"Rafael Xavier de Souza","email":"rxaviers@gmail.com","url":"http://rafael.xavier.blog.br"},"contributors":[{"name":"Ramalingam Kandaswamy Manikandan"}],"license":"MIT","bugs":{"url":"https://github.com/rxaviers/zoned-date-time/issues"},"homepage":"https://github.com/rxaviers/zoned-date-time#readme","scripts":{"test":"eslint --ext .js src && mocha","build":"npm test && mkdir -p dist && rm -f dist/* && echo Building dist/zoned-date-time.js && babel src/zoned-date-time.js -o dist/zoned-date-time.js && echo Done"},"devDependencies":{"babel-cli":"^6.7.7","babel-core":"^6.7.7","babel-eslint":"^6.0.4","babel-preset-es2015":"^6.6.0","chai":"^3.5.0","eslint":"^3.18.0","eslint-config-defaults":"^9.0.0","iana-tz-data":">=2017.1.0","mocha":"^2.4.5"},"gitHead":"9c69cb584fe0a64fa00eb927bade15da0674383c","_id":"zoned-date-time@1.0.0","_shasum":"d80926615db6a1ab2f772f4eb4d38f22cb3624a6","_from":".","_npmVersion":"4.4.0","_nodeVersion":"4.8.0","_npmUser":{"name":"rxaviers","email":"rxaviers@gmail.com"},"dist":{"shasum":"d80926615db6a1ab2f772f4eb4d38f22cb3624a6","tarball":"https://registry.npmjs.org/zoned-date-time/-/zoned-date-time-1.0.0.tgz","integrity":"sha512-bGO57PIXI2V5y9T+vzQPngPLRMY1pPYNAZ0E8HwS9j6slvBPWGsSTS6Qij7wfMOab/RKy0zJRrRD+wYOMBWpVA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCOUxQ1jvxxBmlLhBd7/MMqu4l0obOOuheVt1BIIVo8gAIhAJzCZyQfUbPixegAU2E+0SEyPfiRxANLbUUEXLHVXhqm"}]},"maintainers":[{"name":"rxaviers","email":"rxaviers@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/zoned-date-time-1.0.0.tgz_1498570394846_0.5673009713646024"},"directories":{}},"1.1.0":{"name":"zoned-date-time","version":"1.1.0","description":"A tiny JavaScript Date with full IANA timezone support","main":"src/zoned-date-time.js","repository":{"type":"git","url":"git+ssh://git@github.com/rxaviers/zoned-date-time.git"},"keywords":["date","time","datetime","timezone","zone","metazone","iana"],"author":{"name":"Rafael Xavier de Souza","email":"rxaviers@gmail.com","url":"http://rafael.xavier.blog.br"},"contributors":[{"name":"Ramalingam Kandaswamy Manikandan"}],"license":"MIT","bugs":{"url":"https://github.com/rxaviers/zoned-date-time/issues"},"homepage":"https://github.com/rxaviers/zoned-date-time#readme","scripts":{"test":"eslint --ext .js src && mocha","build":"npm test && mkdir -p dist && rm -f dist/* && echo Building dist/zoned-date-time.js && babel src/zoned-date-time.js -o dist/zoned-date-time.js && echo Done"},"devDependencies":{"babel-cli":"^6.7.7","babel-core":"^6.7.7","babel-eslint":"^6.0.4","babel-preset-es2015":"^6.6.0","chai":"^3.5.0","eslint":"^6.6.0","eslint-config-defaults":"^9.0.0","iana-tz-data":">=2017.1.0","mocha":"^2.4.5"},"gitHead":"53344c6e803bc19554f10e9a98e390ea7a2d3a60","_id":"zoned-date-time@1.1.0","_nodeVersion":"12.14.0","_npmVersion":"6.13.4","dist":{"integrity":"sha512-MhjAUwM1ABOmE9J5SzjNnoXQL83NDaZbRYsZtVTTIjKxXeGJ70GZNEC/NJAyhYiyFiteu24N8Q6gaGhOI/A51A==","shasum":"6df31549f539bdab1acf188515f6e59d904a360e","tarball":"https://registry.npmjs.org/zoned-date-time/-/zoned-date-time-1.1.0.tgz","fileCount":5,"unpackedSize":11539,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvs1MCRA9TVsSAnZWagAAbh0P/RLRx11uzOeETxIO4MBU\nVlB6FfKClmP8orYA20o8flM/VLlwMV8ixXyJC94V2CyjY+X6+O2ClJc/Iby6\nM/U5XfcRGsQlvb01KQo9b6jh0LBFL56SqG9KYg2YmFwABh0qOvW1kjtJtN7v\ntvaerxUxnikt37xuvblRUKLJkesinCqoS9jqy3e+aUuH7Bf6NmnDCQKC8yuP\n9yx4JoNFMddrLTKzYHLbJYDMGy32vKoJyEe/IKl8IkJuJA/pTKE0uW0DqQ1T\nWR6VetuvCvfl2uLX3ZilQyWgaP7k1iS8gJA22pBJD8u81Lrkc1j/hlfr/qr9\nB623F22WT3POpX9/SUT9FPhPJ6/whketNJhka0dUguEdkhFcaX17QSrS0u/6\n8C45OcRBY7Tm9aBqjE9uuu0sscw4QwrhufTuyKX/Ioo5vnbDYWMYxbgPcNYm\nrG5URDrEKbqBPKsv0dIfD/s1SvRuMb6Kvs7mUPhJZXuPGvJKdd9kQpPG4j9E\n49+cmUYo8aVvo5ZfxKUTMn+mubBlAhZkNLvZzvTXCPgfRlni6pRc11HIMY6W\ngteHT9xFjgon11YZ7wa3RpsLLjONACAyiqoQ4jx5EAMTVWv8IXwodlBGM35+\nDe+V9aAYciDp2N7ng4wUY/HgFptzk2t3A65wtougoj9WYgulqCLlr3F+RrLw\nfaEx\r\n=vMIp\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIG4nR4Cksj7oMroEAUAlQhO9eWW4y/VS8oSBqs70nkmMAiEA2AZ83MusFIWHj/EDaafts0pgdaI/WsTziyLXKj8LP5s="}]},"_npmUser":{"name":"rxaviers","email":"rxaviers@gmail.com"},"directories":{},"maintainers":[{"name":"rxaviers","email":"rxaviers@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/zoned-date-time_1.1.0_1606339916392_0.02657352920770828"},"_hasShrinkwrap":false}},"readme":"# ZonedDateTime\n\nA tiny (0.6KB) JavaScript Date with [IANA timezone](https://www.iana.org/time-zones) support.\n\n## Usage\n\n    npm install --save zoned-date-time iana-tz-data\n\n```js\nimport ZonedDateTime from \"zoned-date-time\";\nimport {zoneData} from \"iana-tz-data\";\nlet date = new Date(\"2017-03-15T12:00:00Z\");\n\nlet losAngelesDate = new ZonedDateTime(date, zoneData.America.Los_Angeles);\n// > 2017-03-15T05:00:00.000 PDT (daylight savings)\n\nlet newYorkDate = new ZonedDateTime(date, zoneData.America.New_York);\n// > 2017-03-15T08:00:00.000 EDT (daylight savings)\n\nlet saoPauloDate = new ZonedDateTime(date, zoneData.America.Sao_Paulo);\n// > 2017-03-15T09:00:00.000 -03\n\nlosAngelesDate.isDST(); // > true\nsaoPauloDate.isDST(); // > false\n```\n\n### I18n disclaimer\n\n**Important note on i18n**: If you need to display such information to your users/customers, use an i18n library. For example:\n\n- [Intl.DateTimeFormat](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DateTimeFormat) (see `options.timeZone`)\n- [Globalize](https://github.com/rxaviers/globalize/blob/4c5e48750a22bed83d93897d668acee26270c44a/doc/api/date/date-formatter.md) (see `options.timeZone` of `1.3.0-alpha.0` release)\n\n## API\n\n### Constructor\n\n#### `new ZonedDateTime(date, timeZoneData)`\n\nCreates a new zonedDateTime instance given a `date` and `timeZoneData`.\n\n##### date\n\nA [JavaScript date object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date), i.e., `new Date()`.\n\n##### timeZoneData\n\nThe *zdumped* IANA timezone data (found on the [iana-tz-data](https://github.com/rxaviers/iana-tz-data) package) for the desired timeZoneId. \n\n### Methods\n\n#### `.clone()`\n\nReturns a cloned zoned date time instance.\n\n#### `.getDate()`\n\nReturns the day of the month.\n\n#### `.getDay()`\n\nReturns the day of the week.\n\n#### `.getFullYear()`\n\nReturns the full year, e.g., `2017`.\n\n#### `.getHours()`\n\nReturns the hours, ranges from `0` to `23`.\n\n#### `.getMilliseconds()`\n\nReturns the milliseconds.\n\n#### `.getMinutes()`\n\nReturns the minutes, ranges from `0` to `59`.\n\n#### `.getMonth()`\n\nReturns the month number, ranges from `0` to `11`.\n\n#### `.getSeconds()`\n\nReturns the seconds, ranges from `0` to `59`.\n\n#### `.getTime()`\n\nReturns the numeric value corresponding to the time for the specified date according to universal time, i.e., the epoch time.\n\n#### `.getTimezoneOffset()`\n\nReturns the time zone difference, in minutes, from its zone to UTC.\n\n#### `.isDST()`\n\nReturns a boolean indicating whether the datetime is in daylight savings mode.\n\n#### `.setDate(dayValue)`\n\nSets the day of the object relative to the beginning of the currently set month according to this zone.\n\n##### dayValue\n\nAn integer representing the day of the month.\n\n#### `.setFullYear(yearValue)`\n\nSets the full year according to this zone.\n\n##### yearValue\n\nAn integer specifying the numeric value of the year, for example, 1995.\n\n#### `.setHours(hoursValue)`\n\nSets the hours according to this zone.\n\n##### hoursValue\n\nAn integer between 0 and 23, representing the hour.\n\n#### `.setMilliseconds(millisecondsValue)`\n\nSets the milliseconds according to this zone.\n\n##### millisecondsValue\n\nA number between 0 and 999, representing the milliseconds.\n\n#### `.setMinutes(minutesValue)`\n\nSets the minutes according to this zone.\n\n##### minutesValue\n\nAn integer between 0 and 59, representing the minutes.\n\n#### `.setMonth(monthValue)`\n\nSets the month according to this zone.\n\n##### monthValue\n\nAn integer between 0 and 11, representing the months January through December.\n\n#### `.setSeconds(secondsValue)`\n\nSets the seconds according to this zone.\n\n##### secondsValue\n\nAn integer between 0 and 59, representing the seconds.\n\n#### `.setTime(timeValue)`\n\nSets the numeric value corresponding to the time for the specified date according to universal time, i.e., the epoch time.\n\n##### timeValue\n\nAn integer representing the number of milliseconds since 1 January 1970, 00:00:00 UTC.\n\n#### `.toDate()`\n\nReturns the corresponding `Date` object, i.e., the equivalent date in the runtime time zone.\n\n#### `.toISOString()`\n\nReturns a string in *simplified* extended ISO format ([ISO 8601](http://en.wikipedia.org/wiki/ISO_8601)), which is always 24 or 27 characters long (**YYYY-MM-DDTHH:mm:ss.sssZ** or **±YYYYYY-MM-DDTHH:mm:ss.sssZ**`, respectively`). The timezone is always zero UTC offset, as denoted by the suffix \"`Z`\".\n\n#### `.toJSON()`\n\nReturns a string representation of the [`Date`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) object.\n\n#### `.toUTCString()`\n\nConverts a date to a string, using the UTC time zone.\n\n## License\n\nMIT © [Rafael Xavier de Souza](http://rafael.xavier.blog.br)\n\nMIT © [Ramalingam Kandaswamy Manikandan](rajavelmani@gmail.com)\n","maintainers":[{"name":"rxaviers","email":"rxaviers@gmail.com"}],"time":{"modified":"2022-06-29T17:48:57.695Z","created":"2017-04-06T19:05:26.020Z","0.0.3":"2017-04-06T19:05:26.020Z","0.0.4":"2017-04-15T18:42:04.568Z","1.0.0":"2017-06-27T13:33:15.901Z","1.1.0":"2020-11-25T21:31:56.512Z"},"homepage":"https://github.com/rxaviers/zoned-date-time#readme","keywords":["date","time","datetime","timezone","zone","metazone","iana"],"repository":{"type":"git","url":"git+ssh://git@github.com/rxaviers/zoned-date-time.git"},"contributors":[{"name":"Ramalingam Kandaswamy Manikandan"}],"author":{"name":"Rafael Xavier de Souza","email":"rxaviers@gmail.com","url":"http://rafael.xavier.blog.br"},"bugs":{"url":"https://github.com/rxaviers/zoned-date-time/issues"},"license":"MIT","readmeFilename":"README.md"}