reactjs [android.manifest]:使用AndroidManifestBaseMod:androidManifest.manifest.hasOwnProperty不是函数

k4ymrczo  于 2023-08-04  发布在  React
关注(0)|答案(1)|浏览(71)

我正在努力建设世博会(EAS)。但是得到这个错误。我想我在app.json或app.config.json中遗漏了一些东西。我已经在这上面一周了。先谢了。

错误代码

`expo:config-plugins:android:package找到包“com.sh411.CFlow”for type“debug”+0ms expo:config-plugins:android:package找到包“com.sh411.CFlow”for type“main”+1ms expo:config-plugins:android:package找到包“com.sh411.CFlow”for type“release”+0ms android.危险的:使用AndroidExpoPlugins使用插件使用StaticPlugin使用AndroidIcons使用DangerousMod

  • 配置同步android.危险:withAndroidExpoPlugins withPlugins withStaticPlugin withGoogleServicesFile withDangerousMod
  • 配置同步android.危险:with SplashScreen with AndroidSplashScreen with Plugins with StaticPlugin with AndroidSplashDrawables with DangerousMod
  • 配置同步android.危险:with SplashScreen with AndroidSplashScreen with Plugins with StaticPlugin with AndroidSplashImages with DangerousMod
  • 配置同步android.危险:带Fallback带插件带静态插件带通知图标带DangerousMod
  • 配置同步android.manifest:带DefaultBaseMods带AndroidBaseMods带GeneratedBaseMods带AndroidManifestBaseMods
  • 配置同步expo:config-plugins:base-mods mods mods.android.manifest:文件路径:/Users/sh/CFlowMobile/android/app/src/main/AndroidManifest.xml +83ms android.manifest:with AndroidExpoPlugins with Plugins with StaticPlugin with AndroidIcons with AndroidManifest
  • 配置同步**android.manifest:withAndroidExpoPlugins withPlugins withStaticPlugin withPermissions withAndroidManifest
  • 配置同步配置同步失败**

TypeError:[android.manifest]:使用AndroidManifestBaseMod:androidManifest.manifest.hasOwnProperty不是函数TypeError:[android.manifest]:使用AndroidManifestBaseMod:androidManifest.manifest.hasOwnProperty不是setAndroidPermissions(/Users/sh/CFlowMobile/node_modules/@expo/prebuild-config/node_modules/@expo/config-plugins/build/android/Permissions.js:123:33)`

app.config.js

module.exports = {
      expo: {
        name: 'CFlow',
        slug: 'CFlow',
        version: '1.0.0',
        orientation: 'portrait',
        icon: './assets/icon.png',
        android: {
          package: 'com.sh411.CFlow',
          manifest: {
            permissions: ['CAMERA', 'READ_EXTERNAL_STORAGE'],
            usesCleartextTraffic: true,
            application: {
              activity: {
                'android:windowSoftInputMode': 'adjustPan',
              },
            },
          },
        },
        ios: {
          bundleIdentifier: 'com.sh411.CFlow',
        },
        androidStatusBar: {
          backgroundColor: '#ffffff',
          barStyle: 'dark-content',
          translucent: true,
        },
        splash: {
          image: './assets/splash.png',
          resizeMode: 'contain',
          backgroundColor: '#ffffff',
        },
        mods: {
          android: {
            manifest: {
              permissions: ['CAMERA', 'READ_EXTERNAL_STORAGE'],
              usesCleartextTraffic: true,
              application: {
                activity: {
                  'android:windowSoftInputMode': 'adjustPan',
                },
              },
            },
          },
          ios: {
            infoPlist: {
              NSCameraUsageDescription: 'This app uses the camera to take photos',
              NSPhotoLibraryUsageDescription: 'This app needs access to your photo library',
            },
          },
        },
        extra: {
          eas: {
            projectId: 'b1c7ca55-d671-4f7b-a550-xxx',
          },
        },
      },
    };

字符串
已尝试更改app.json和app.config.json并更新依赖项。

lrpiutwd

lrpiutwd1#

希望你能弄清楚这一点,但以防其他人偶然发现这一点。我也遇到了由旧版本xml2js引起的相同错误。看这篇文章。https://github.com/Leonidas-from-XIV/node-xml2js/issues/670.xml2js在6.1版中修复了这个问题。在我的例子中,我使用Yarn分辨率来安装最新版本。

相关问题