Search code examples
androidangularionic-frameworkcapacitormobile-development

VM deprecated warning and deploying an Ionic App


npm WARN deprecated [email protected]: The library contains critical security issues and should not be used for production! The maintenance of the project has been discontinued. Consider migrating your code to isolated-vm.

The above VM deprecated warning keeps popping up when a new ionic angular project is initiated. And after searching on what VM2 is i got the question, if the project can be deployed as it is.

I tried searching for any articles regarding it but i didnt get much info on it. My main question is... if im developing an ionic capacitor app what is the correct way to deploy a production version of it to playstore and does this VM2 deprecation which mentions that the sandbox should not be used for production be changed or kept as it is. Furthermore after a unique url is given to the ionic mobile app in the config is there a need for it to be hosted like a normal website or does ionic automatically handle that for us.

As im new to creating production versions of mobile apps, my knowledge on deploying them is limited so i hope to get any possible advices as well.


Solution

  • This appears to be related to the Ionic CLI, I found a bug report and a detailed explanation at the following link: https://github.com/ionic-team/ionic-cli/issues/5030. Based on the link, the superagent-proxy package is using vm2, and they look to be migrating away from it.

    Pull request that appears to still have issues: https://github.com/ionic-team/ionic-cli/pull/5042

    I could be wrong but this looks to be specific to the CLI and not a deployed Ionic App, if anyone knows different please comment.

    Also, it appears the author of the pull request gave up.