Tuesday, July 30, 2024
HomeiOS Developmentios - React native permission warning add loading: No permission handler detected

ios – React native permission warning add loading: No permission handler detected


I’ve a react native mission. Inside this react native mission, I need to get a customers location if they offer permission in order that I can get their longitude and latitude. I used to be not getting a difficulty once I first implimented it however I get an error / warning all the sudden about permissions and I’m not positive the place this error is coming from.

Right here is the display screen that I’m seeing:

Permission screen

I’ve made a number of modifications to my mission however none of it’s being efficient

Right here is my podfile:

# Resolve react_native_pods.rb with node to permit for hoisting
require Pod::Executable.execute_command('node', ['-p',
  'require.resolve(
    "react-native/scripts/react_native_pods.rb",
    {paths: [process.argv[1]]},
  )', __dir__]).strip

platform :ios, '15.0'
prepare_react_native_project!

use_frameworks! :linkage => :static
$RNFirebaseAsStaticFramework = true

goal 'Grubber' do
  config = use_native_modules!

  use_react_native!(
    :path => config[:reactNativePath],
    # Eradicating Flipper fully
    # :flipper_configuration => flipper_config,  # Take away this line
    # An absolute path to your software root.
    :app_path => "#{Pod::Config.occasion.installation_root}/.."
  )

  # Add the required permissions pods with modular headers
  permissions_path="../node_modules/react-native-permissions/ios"
  pod 'Permission-LocationAlways', :path => "#{permissions_path}/LocationAlways/Permission-LocationAlways.podspec"
  pod 'Permission-LocationWhenInUse', :path => "#{permissions_path}/LocationWhenInUse/Permission-LocationWhenInUse.podspec"
  
  # Add Firebase pods
  pod 'Firebase/Core'
  pod 'Firebase/Messaging'

  goal 'GrubberTests' do
    inherit! :full
    # Pods for testing
  finish

  post_install do |installer|
    # https://github.com/fb/react-native/blob/primary/packages/react-native/scripts/react_native_pods.rb#L197-L202
    react_native_post_install(
      installer,
      config[:reactNativePath],
      :mac_catalyst_enabled => false
    )

    installer.pods_project.targets.every do |goal|
      goal.build_configurations.every do |config|
        config.build_settings['CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER'] = 'NO'
        config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '15.0'
      finish
    finish
  finish
finish

Right here is my information.plist:

<?xml model="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist model="1.0">
<dict>
    <key>CFBundleDevelopmentRegion</key>
    <string>en</string>
    <key>CFBundleDisplayName</key>
    <string>Grubber</string>
    <key>CFBundleExecutable</key>
    <string>$(EXECUTABLE_NAME)</string>
    <key>CFBundleIdentifier</key>
    <string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
    <key>CFBundleInfoDictionaryVersion</key>
    <string>6.0</string>
    <key>CFBundleName</key>
    <string>$(PRODUCT_NAME)</string>
    <key>CFBundlePackageType</key>
    <string>APPL</string>
    <key>CFBundleShortVersionString</key>
    <string>$(MARKETING_VERSION)</string>
    <key>CFBundleSignature</key>
    <string>????</string>
    <key>CFBundleVersion</key>
    <string>$(CURRENT_PROJECT_VERSION)</string>
    <key>FirebaseAppDelegateProxyEnabled</key>
    <false/>
    <key>LSApplicationCategoryType</key>
    <string></string>
    <key>LSApplicationQueriesSchemes</key>
    <array>
        <string>mailto</string>
    </array>
    <key>LSRequiresIPhoneOS</key>
    <true/>
    <key>NSAppTransportSecurity</key>
    <dict>
        <key>NSAllowsArbitraryLoads</key>
        <false/>
        <key>NSAllowsLocalNetworking</key>
        <true/>
    </dict>
    <key>NSLocationAlwaysUsageDescription</key>
    <string>We want your location to point out close by eating places.</string>
    <key>NSLocationWhenInUseUsageDescription</key>
    <string>We want your location to point out close by eating places.</string>
    <key>NSPhotoLibraryUsageDescription</key>
    <string>Your images are used to can help you choose photos to connect to your posts.</string>
    <key>UIBackgroundModes</key>
    <array>
        <string>fetch</string>
        <string>location</string>
        <string>processing</string>
        <string>remote-notification</string>
    </array>
    <key>UILaunchStoryboardName</key>
    <string>LaunchScreen</string>
    <key>UIRequiredDeviceCapabilities</key>
    <array>
        <string>armv7</string>
    </array>
    <key>UISupportedInterfaceOrientations</key>
    <array>
        <string>UIInterfaceOrientationPortrait</string>
    </array>
    <key>UISupportedInterfaceOrientations~ipad</key>
    <array>
        <string>UIInterfaceOrientationLandscapeLeft</string>
        <string>UIInterfaceOrientationLandscapeRight</string>
        <string>UIInterfaceOrientationPortrait</string>
    </array>
    <key>UIViewControllerBasedStatusBarAppearance</key>
    <false/>
</dict>
</plist>

if anybody is aware of how you can assist me repair this concern, I’d be very grateful.

Everytime I construct the mission in xcode I run the next command in terminal:

cd ios
rm -rf Pods Podfile.lock ~/Library/Developer/Xcode/DerivedData
pod set up 
cd ..
npx react-native run-ios --device "AbuVibes iPhone"   



Supply hyperlink

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments