Babel 7 em nodejs não funciona no ie


(Rafael) #1

Olá,

Estou tentando rodar minha api node no internet explore mas sem sucesso
o meu arquivo

.babelrc:

  {
    "presets":["@babel/preset-react"],
    "plugins": [
        "@babel/plugin-transform-flow-strip-types",
        "@babel/plugin-transform-modules-commonjs",
        "@babel/plugin-transform-async-to-generator",
        "@babel/plugin-transform-strict-mode",
        "@babel/plugin-transform-runtime"
    ]
}

e meu package.json:

{
  "name": "api",
  "version": "0.0.0",
  "private": true,
  "scripts": {
    "babel": "@babel-node app.js"
  },
  "dependencies": {
    "@babel/cli": "^7.0.0-beta.42",
    "@babel/core": "^7.1.2",
    "@babel/node": "^7.0.0",
    "@babel/plugin-transform-async-to-generator": "^7.1.0",
    "@babel/plugin-transform-flow-strip-types": "^7.0.0",
    "@babel/plugin-transform-modules-commonjs": "^7.1.0",
    "@babel/plugin-transform-runtime": "^7.1.0",
    "@babel/plugin-transform-strict-mode": "^7.0.0",
    "@babel/polyfill": "^7.0.0",
    "@babel/preset-react": "^7.0.0",
    "@babel/runtime": "^7.1.2",
    "@babel/runtime-corejs2": "^7.1.2",
    "async": "latest",
    "autoprefixer": "^6.5.4",
    "babel-preset-es2015": "^6.24.1",
    "basic-auth-connect": "latest",
    "bcrypt-nodejs": "0.0.3",
    "body-parser": "~1.13.2",
    "client-sessions": "latest",
    "cloudinary": "^1.11.0",
    "connect": "latest",
    "connect-flash": "latest",
    "cookie-parser": "~1.3.5",
    "cors": "^2.8.4",
    "dateformat": "latest",
    "debug": "~2.2.0",
    "ejs": "~2.3.3",
    "express": "~4.13.1",
    "express-mailer": "^0.3.0",
    "express-session": "latest",
    "express-validation": "^1.0.2",
    "express-validator": "^5.3.0",
    "fs-extra": "latest",
    "guid": "0.0.12",
    "http-proxy": "latest",
    "jsonwebtoken": "^7.4.0",
    "md5": "latest",
    "mime": "latest",
    "mongoose": "latest",
    "morgan": "~1.6.1",
    "multer": "latest",
    "mysql": "^2.16.0",
    "mysql2": "^1.6.1",
    "node-constants": "latest",
    "nodemailer": "^2.4.1",
    "nodemailer-smtp-transport": "^2.5.0",
    "nodemon": "latest",
    "numeral": "latest",
    "passport": "latest",
    "pm2": "latest",
    "request": "latest",
    "sequelize": "^4.38.0",
    "serve-favicon": "~2.3.0",
    "simple-encryptor": "latest",
    "socket.io": "^2.1.1",
    "underscore": "latest",
    "vue": "^2.5.17",
    "vue-cli": "^2.9.6"
  },
  "browserslist": [
    "last 2 version",
    "> 1%",
    "IE <= 8"
  ]
}

para executar eu uso “npm run babel” alguém já passou por isso?