xref: /expo/packages/expo-task-manager/plugin/build/withTaskManager.js (revision ca5a2fa2)
  • Home
  • History
  • Annotate
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3const config_plugins_1 = require("@expo/config-plugins");
4const pkg = require('expo-task-manager/package.json');
5const withTaskManager = (config) => {
6    config = (0, config_plugins_1.withInfoPlist)(config, (config) => {
7        if (!Array.isArray(config.modResults.UIBackgroundModes)) {
8            config.modResults.UIBackgroundModes = [];
9        }
10        if (!config.modResults.UIBackgroundModes.includes('fetch')) {
11            config.modResults.UIBackgroundModes.push('fetch');
12        }
13        return config;
14    });
15    return config;
16};
17exports.default = (0, config_plugins_1.createRunOncePlugin)(withTaskManager, pkg.name, pkg.version);
18

served by {OpenGrok

Last Index Update: Tue Oct 21 18:42:31 GMT 2025