react-tz
v1.0.0
Published
A beautiful, clean and UX friendly timezone selector
Downloads
7
Maintainers
Readme
React-tz
An ultimate timezone picker for React. Built on top of react-select, moment-timezone and using real timezone data from timezone-db
Demo
mikevercoelen.github.io/react-tz
Requirements
You need to make sure you have these deps installed first:
- react
^16.8.6
- react-select
2.4.3^
- moment-timezone
2.24.0^
Installation
npm install react-tz --save
With peer deps:
npm install react react-select moment-timezone react-tz --save
Example
import React, { useState } from 'react'
import { TimezoneSelect } from 'react-tz'
const Demo = () => {
const [timezone, setTimezone] = useState(null)
return (
<TimezoneSelect
value={timezone}
onChange={setTimezone} />
)
}
export default Demo