React-native-permissions: Memory usage increased ~15MB if just install this module

Created on 30 Sep 2019  路  4Comments  路  Source: zoontek/react-native-permissions

thanks for this awesome work.
after some memory tests, i find 12~15 MB memory usage due to installing just this module.
if i dont import this module in my code also this amount used in app
i only request user to give camera and read/write stuff if some points.
installed with both manual and cocopod methods for test
any listener or any emiter in this module makes memory usage in native code?

"react": "^16.8.3",
"react-native": "^0.59.10",
"react-native-permissions": "^1.1.1

Most helpful comment

Can anyone share on how to use jetify -r? I am newbie and can't figure out how to use it.. Thank you

  • Install jetifier with npm install --save-dev jetifier or yarn add --dev jetifier
  • In your package.json scripts, add
"scripts": {
  "postinstall": "jetify -r"
},
  • Re-run npm install or yarn

All 4 comments

@club9822 Version 1.x suffers from multiple memory leaks on iOS. Can you upgrade to 2.0.0? It works pretty great with jetify -r, and you will only install permission handlers for permissions you actually need (camera)

tested on ios and seems this leaks gone. thanks 馃憤

Can anyone share on how to use jetify -r? I am newbie and can't figure out how to use it.. Thank you

Can anyone share on how to use jetify -r? I am newbie and can't figure out how to use it.. Thank you

  • Install jetifier with npm install --save-dev jetifier or yarn add --dev jetifier
  • In your package.json scripts, add
"scripts": {
  "postinstall": "jetify -r"
},
  • Re-run npm install or yarn
Was this page helpful?
0 / 5 - 0 ratings