解决nodejs不支持async和await关键字的问题

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/michael51/article/details/87860296

需要3个依赖

$ npm install --save-dev babel-cli babel-preset-es2015 babel-preset-es2017

Create .babelrc in the project root folder with the following contents:

{ “presets”: [“es2015”,“es2017”] }

猜你喜欢

转载自blog.csdn.net/michael51/article/details/87860296
今日推荐