Skip to content

Commit 139f994

Browse files
Martin Konicekfacebook-github-bot-7
Martin Konicek
authored and
facebook-github-bot-7
committed
Don't use arrow functions with Flow types to fix website generation
Summary: Our custom jsdocs parser doesn't support the syntax yet. public Reviewed By: bestander Differential Revision: D2739861 fb-gh-sync-id: eefc3c54b98e06597ca7d93396aa4fe3a92d4a58
1 parent f9f123b commit 139f994

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

Examples/UIExplorer/NetInfoExample.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ exports.examples = [
176176
{
177177
platform: 'android',
178178
title: 'NetInfo.isConnectionExpensive (Android)',
179-
description: 'Asycnronously check isConnectionExpensive',
179+
description: 'Asynchronously check isConnectionExpensive',
180180
render(): ReactElement { return <IsConnectionExpensive />; }
181181
},
182182
];

Libraries/Network/NetInfo.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,15 @@ const _subscriptions = new Map();
5858

5959
let _isConnected;
6060
if (Platform.OS === 'ios') {
61-
_isConnected = (reachability: ReachabilityStateIOS): bool => {
61+
_isConnected = function(
62+
reachability: ReachabilityStateIOS,
63+
): bool {
6264
return reachability !== 'none' && reachability !== 'unknown';
6365
};
6466
} else if (Platform.OS === 'android') {
65-
_isConnected = (connectionType: ConnectivityStateAndroid) : bool => {
67+
_isConnected = function(
68+
connectionType: ConnectivityStateAndroid,
69+
): bool {
6670
return connectionType !== 'NONE' && connectionType !== 'UNKNOWN';
6771
};
6872
}

0 commit comments

Comments
 (0)