ionic4 执行ionic cordova run android 时报错Could not find plugin "proposal-numeric-separator". Ensure there is an entry in ./available-plugins.js for it.
![](https://img2020.cnblogs.com/blog/1603899/202004/1603899-20200401133120833-134479019.png)
解决方法:
1. 在package.json中加上:
"resolutions": {
"@babel/preset-env": "^7.8.7"
},
![](https://img2020.cnblogs.com/blog/1603899/202004/1603899-20200401133752584-2037681256.png)
2. 执行 npx npm-force-resolutions
3.执行 npm install
我亲自试了,确实解决了,但是之后又安了一个vconsole,再次执行ionic cordova run android 又报错,于是又重复了上面2,3两步,然后又正常了。我还不太理解这个原理。这是从网上找到的解决方法。https://stackoverflow.com/questions/60787334/ionic-android-build-fails-with-could-not-find-plugin-proposal-numeric-separator?answertab=active#tab-top
喜欢的话,请点赞,转发、收藏、评论,谢谢!