react-native-paper: Cannot find module 'react-native-paper/babel' when generating production build for android

Without Expo & Using - “react-native”: “0.60.4”, “react-native-paper”: “^3.0.0-alpha.3”,

babel.config.js–

module.exports = {
  presets: ['module:metro-react-native-babel-preset'],
  env: {
    production: {
      plugins: ['react-native-paper/babel'],
    },
  },
};

when trying to generate APK on windows system getting this error. tried on other projects using RN paper “^3.0.0-alpha.3”, got same error

rn paper issus

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 27 (13 by maintainers)

Most upvoted comments

We released 3.0.0-alpha.5 and successfully build release APK

@ripzery @zyxel648 Thanks for the report, we will look into it ASAP

The issue might be related to the fact, that after migration to typescript .js files aren’t copied to lib folder. src/babel/index.js is a js file

so there is no react-native-paper/babel.js but there is react-native-paper/lib/module/src/babel/index.js