来自流星构建的箭头功能正在崩溃英雄部署 [英] Arrow function from meteor build is crashing heroku deploy

查看:135
本文介绍了来自流星构建的箭头功能正在崩溃英雄部署的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在使用流星的英雄上部署了一个js应用程序。该构建在localhost上工作,但在heroku服务器上失败。我检查了日志,发现这一点:

  .js:312:12)
2017-03-18T03:29 :07.070711 + 00:00 app [web.1]:const unicodeNormalizePath =(path)=> {
2017-03-18T03:29:07.074825 + 00:00 app [web.1]:at Module.require(module.js:364:17)
2017-03-18T03:29: 07.074821 + 00:00 app [web.1]:SyntaxError:Unexpected token>
2017-03-18T03:29:07.074824 + 00:00 app [web.1]:at Module.load(module.js:356:32)
2017-03-18T03:29:07.070741 +00:00 app [web.1]:^

这让我觉得这不是兼容ES6箭头功能,所以我安装了emmascript流星使其与ES5兼容。



这还没有解决问题,而这个箭头功能还在崩溃网络应用程序。



有关如何阻止这个的任何建议?

解决方案

同样的问题使用,可能是一个老建筑包Heroku。我切换到构建包 https://github.com/AdmitHub/meteor-buildpack-horse .git ,它完美解决了问题。



工作buildpack:

 code> heroku buildpacks:set https://github.com/AdmitHub/meteor-buildpack-horse.git 

我还通过键入以下内容来禁用以前的buildpack:

  heroku config:unset LINK_TO_OLD_BUILDPACK_REPO 

我使用的旧版本是 https://github.com/jordansissel/heroku-buildpack-meteor.git


I have deployed a js application on heroku that uses meteor. The build works on localhost but fails on the heroku server. I checked the logs and found this:

.js:312:12)
2017-03-18T03:29:07.070711+00:00 app[web.1]: const unicodeNormalizePath     = (path) => {
2017-03-18T03:29:07.074825+00:00 app[web.1]:     at Module.require (module.js:364:17)
2017-03-18T03:29:07.074821+00:00 app[web.1]: SyntaxError: Unexpected token >
2017-03-18T03:29:07.074824+00:00 app[web.1]:     at Module.load (module.js:356:32)
2017-03-18T03:29:07.070741+00:00 app[web.1]:                                          ^

This gave me the thought that it was not compatible with ES6 arrow functions so I installed ecmascript for meteor to make it compatible with ES5.

This has not solved the problem and this arrow function is still crashing the web app.

Any suggestions on how to stop this?

解决方案

I had the same problem using, probably, an old buildpack for Heroku. I switched to the buildpack https://github.com/AdmitHub/meteor-buildpack-horse.git and it solved the problem perfectly.

Working buildpack:

heroku buildpacks:set https://github.com/AdmitHub/meteor-buildpack-horse.git

I also disabled the previous buildpack by typing:

heroku config:unset LINK_TO_OLD_BUILDPACK_REPO

The old one I used was https://github.com/jordansissel/heroku-buildpack-meteor.git

这篇关于来自流星构建的箭头功能正在崩溃英雄部署的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆