mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-05-09 13:37:58 +08:00
Summary: Related to #22100 Turn Flow strict mode on for DatePickerAndroid - [x] npm run prettier - [ ] npm run flow-check-ios - [ ] npm run flow-check-android This error was happend #22101 #22048 [GENERAL] [ENHANCEMENT] [Components/DatePickerAndroid/DatePickerAndroid.android.js] - Flow strict mode [GENERAL] [ENHANCEMENT] [Components/DatePickerAndroid/DatePickerAndroid.ios.js] - Flow strict mode Pull Request resolved: https://github.com/facebook/react-native/pull/22106 Reviewed By: TheSavior Differential Revision: D12919276 Pulled By: RSNara fbshipit-source-id: 79672b2894435ca3c9988fefee3685700a8d8936
29 lines
638 B
JavaScript
29 lines
638 B
JavaScript
/**
|
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*
|
|
* @format
|
|
* @flow strict-local
|
|
*/
|
|
|
|
'use strict';
|
|
|
|
type Options = $ReadOnly<{|
|
|
date?: ?(Date | number),
|
|
minDate?: ?(Date | number),
|
|
maxDate?: ?(Date | number),
|
|
mode?: ?('calender' | 'spinner' | 'default'),
|
|
|}>;
|
|
|
|
const DatePickerAndroid = {
|
|
async open(options: Options): Promise<void> {
|
|
return Promise.reject({
|
|
message: 'DatePickerAndroid is not supported on this platform.',
|
|
});
|
|
},
|
|
};
|
|
|
|
module.exports = DatePickerAndroid;
|