[英]Ember SyntaxError Unexpected Token; NodeJS Module Related
I am having an issue with Ember building.我遇到了 Ember 构建的问题。 I have tried doing
npm clean cache
, deleting the node_modules
folder, and then npm install
.我试过做
npm clean cache
,删除node_modules
文件夹,然后npm install
。 I have also tried copying the ember-cli
and ember-cli-htmlbars-inline-precompile
folders from sources that I know build correctly and are using the same versions.我还尝试从我知道正确构建并使用相同版本的源复制
ember-cli
和ember-cli-htmlbars-inline-precompile
文件夹。
SyntaxError: Unexpected token :
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:373:25)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Project.require (*****\node_modules\ember-cli\lib\models\project.js:280:12)
at Project.config (*****\node_modules\ember-cli\lib\models\project.js:198:26)
at Class.module.exports.projectConfig (*****\node_modules\ember-cli-htmlbars-inline-precompile\index.js:103:25)
After searching and searching, I ran across this question .经过搜索和搜索,我遇到了这个问题。 It turns out that my /config/environment.js was corrupt, which was resulting in this error.
事实证明,我的 /config/environment.js 已损坏,从而导致此错误。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.