rn-timezone-offset

1.0.2 • Public • Published

# rn-timezone-offset

npm version

Easy time manager (based on UTC offset) for different timezones in React Native app.

Easy time manager (based on UTC offset) for different timezones in React Native app.

This stand-alone library will setup the date based on timezone offset. Mostly this will be helpful in setting date in DatePickers in React-Native.

This library takes help from great date and timezone management libraries, "Moment" and "Moment-Timezone".

Usage

npm i rn-timezone-offset

var tZoner = require('rn-timezone-offset');
console.log(tZoner.toLocalTZ("1971-07-05"));

The library was created as a fix for timezone issue where RDS was saving the date in UTC format and client DatePickers (iOS and Android) were setting the date one day prior to the normal date in certain timezones.

Package Sidebar

Install

npm i rn-timezone-offset

Weekly Downloads

2

Version

1.0.2

License

ISC

Unpacked Size

28.7 kB

Total Files

5

Last publish

Collaborators

  • anoojkrishnan