Search code examples
xcodereact-nativexcode10background-fetchxcode-scheme

React Native: Simulate Background Fetch disabled


I'm trying to simulate background fetch in a React Native project

React Native version 0.57.3 Xcode Version 10.0 (10A255)

I've opened the ios project on Xcode and then I build the project then run it, but the option to simulate background fetch is disabled as screenshot below shows:

Simulate background fetch disabled

I got the same result running in Simulator either in a real device.

How to get it working? or whats the cause of it?

The project config is as the screenshot:

Xcode: Project Capabilites screenshot

Xcode: Scheme Options


Solution

  • I got Simulate background fetch enabled by going to:

    Xcode Menu > Product > Scheme > Edit Scheme and change Executable from Ask on launch to the app executable