Browse Source

Remove Flow types from example

Jamon Holmgren 6 years ago
parent
commit
f6ed462dd4
1 changed files with 14 additions and 14 deletions
  1. 14
    14
      examples/WebViewExample.js

+ 14
- 14
examples/WebViewExample.js View File

31
 var DEFAULT_URL = 'https://m.facebook.com';
31
 var DEFAULT_URL = 'https://m.facebook.com';
32
 const FILE_SYSTEM_ORIGIN_WHITE_LIST = ['file://*', 'http://*', 'https://*'];
32
 const FILE_SYSTEM_ORIGIN_WHITE_LIST = ['file://*', 'http://*', 'https://*'];
33
 
33
 
34
-class WebViewExample extends React.Component<{}, $FlowFixMeState> {
34
+class WebViewExample extends React.Component {
35
   state = {
35
   state = {
36
     url: DEFAULT_URL,
36
     url: DEFAULT_URL,
37
     status: 'No Page Loaded',
37
     status: 'No Page Loaded',
156
   };
156
   };
157
 }
157
 }
158
 
158
 
159
-class Button extends React.Component<$FlowFixMeProps> {
159
+class Button extends React.Component {
160
   _handlePress = () => {
160
   _handlePress = () => {
161
     if (this.props.enabled !== false && this.props.onPress) {
161
     if (this.props.enabled !== false && this.props.onPress) {
162
       this.props.onPress();
162
       this.props.onPress();
174
   }
174
   }
175
 }
175
 }
176
 
176
 
177
-class ScaledWebView extends React.Component<{}, $FlowFixMeState> {
177
+class ScaledWebView extends React.Component {
178
   state = {
178
   state = {
179
     scalingEnabled: true,
179
     scalingEnabled: true,
180
   };
180
   };
210
   }
210
   }
211
 }
211
 }
212
 
212
 
213
-class MessagingTest extends React.Component<{}, $FlowFixMeState> {
213
+class MessagingTest extends React.Component {
214
   webview = null;
214
   webview = null;
215
 
215
 
216
   state = {
216
   state = {
230
     }
230
     }
231
   };
231
   };
232
 
232
 
233
-  render(): React.Node {
233
+  render() {
234
     const { messagesReceivedFromWebView, message } = this.state;
234
     const { messagesReceivedFromWebView, message } = this.state;
235
 
235
 
236
     return (
236
     return (
267
   }
267
   }
268
 }
268
 }
269
 
269
 
270
-class InjectJS extends React.Component<{}> {
270
+class InjectJS extends React.Component {
271
   webview = null;
271
   webview = null;
272
   injectJS = () => {
272
   injectJS = () => {
273
     const script = 'document.write("Injected JS ")';
273
     const script = 'document.write("Injected JS ")';
411
 </html>
411
 </html>
412
 `;
412
 `;
413
 
413
 
414
-exports.displayName = (undefined: ?string);
414
+exports.displayName = undefined;
415
 exports.title = '<WebView>';
415
 exports.title = '<WebView>';
416
 exports.description = 'Base component to display web content';
416
 exports.description = 'Base component to display web content';
417
 exports.examples = [
417
 exports.examples = [
418
   {
418
   {
419
     title: 'Simple Browser',
419
     title: 'Simple Browser',
420
-    render(): React.Element<any> {
420
+    render() {
421
       return <WebViewExample />;
421
       return <WebViewExample />;
422
     },
422
     },
423
   },
423
   },
424
   {
424
   {
425
     title: 'Scale Page to Fit',
425
     title: 'Scale Page to Fit',
426
-    render(): React.Element<any> {
426
+    render() {
427
       return <ScaledWebView />;
427
       return <ScaledWebView />;
428
     },
428
     },
429
   },
429
   },
430
   {
430
   {
431
     title: 'Bundled HTML',
431
     title: 'Bundled HTML',
432
-    render(): React.Element<any> {
432
+    render() {
433
       return (
433
       return (
434
         <WebView
434
         <WebView
435
           style={{
435
           style={{
445
   },
445
   },
446
   {
446
   {
447
     title: 'Static HTML',
447
     title: 'Static HTML',
448
-    render(): React.Element<any> {
448
+    render() {
449
       return (
449
       return (
450
         <WebView
450
         <WebView
451
           style={{
451
           style={{
460
   },
460
   },
461
   {
461
   {
462
     title: 'POST Test',
462
     title: 'POST Test',
463
-    render(): React.Element<any> {
463
+    render() {
464
       return (
464
       return (
465
         <WebView
465
         <WebView
466
           style={{
466
           style={{
479
   },
479
   },
480
   {
480
   {
481
     title: 'Messaging Test',
481
     title: 'Messaging Test',
482
-    render(): React.Element<any> {
482
+    render() {
483
       return <MessagingTest />;
483
       return <MessagingTest />;
484
     },
484
     },
485
   },
485
   },
486
   {
486
   {
487
     title: 'Inject JavaScript',
487
     title: 'Inject JavaScript',
488
-    render(): React.Element<any> {
488
+    render() {
489
       return <InjectJS />;
489
       return <InjectJS />;
490
     },
490
     },
491
   },
491
   },