Files
react-native/flow/use-subscription.js
T
Eli White 57efe44759 Move flow definitions to react-native
Summary:
These definitions make these libraries act as flow strict. We have them internally but need them in react native to be able to make files in react native flow strict.

Internally our flowconfig includes all the configs in react-native-github.

Changelog:
[Internal]: Add flow strict type definitions for modules

Reviewed By: zackargyle

Differential Revision: D18839594

fbshipit-source-id: d523e15f00a9cfa66d3789bb249655bcbe6d04eb
2019-12-05 16:06:45 -08:00

20 lines
449 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.
*
* @flow strict
* @format
* @nolint
*/
'use strict';
declare module 'use-subscription' {
declare export function useSubscription<Value>(subscription: {|
getCurrentValue: () => Value,
subscribe: (callback: Function) => () => void,
|}): Value;
}