Update HeadlessJSAndroid.md explaining parameters
Summary: HeadlessJsTaskConfig parameters can be unclear, so I added one more parameter that was left set by default and the respective comments. Closes https://github.com/facebook/react-native/pull/16054 Differential Revision: D5881373 Pulled By: hramos fbshipit-source-id: 3d271f73921417d82e3a2c7a1aaabe92aef7ec69
This commit is contained in:
parent
1aeb767a37
commit
f25233b15f
|
@ -43,7 +43,9 @@ public class MyTaskService extends HeadlessJsTaskService {
|
|||
return new HeadlessJsTaskConfig(
|
||||
"SomeTaskName",
|
||||
Arguments.fromBundle(extras),
|
||||
5000);
|
||||
5000, // timeout for the task
|
||||
false // optional: defines whether or not the task is allowed in foreground. Default is false
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue