]> git.immae.eu Git - github/fretlink/time-picker.git/blob - src/util/index.js
Merge pull request #1 from react-component/update-20151120
[github/fretlink/time-picker.git] / src / util / index.js
1 import DateTimeFormat from 'gregorian-calendar-format';
2
3 export function getFormatter(format, locale) {
4 if (typeof format === 'string') {
5 return new DateTimeFormat(format, locale.format);
6 }
7 return format;
8 }