2016-11-09 3 views
3

最近MeteorとReactで地面から降りてきました。私はMeteorウェブサイトのtutorialに問題なく続きました。Meteorアプリケーションを提供しようとしているときに「babel-runtime」エラー

次にもう1つのプロジェクトを作成して、別のtutorial(旧バージョンのMeteorの場合)を実行しようとしました。ラインのどこかに、Meteorはあいまいな誤りを投げ始めました。もう一度新鮮な状態にしてみると、Meteorの再インストールが終わり、不平を言った。

しかし、私は再び同じ問題を抱えています。具体的には、ブランドの新しいプロジェクトの作成後:

meteor create myproject 
cd myproject 
meteor 

サーバは次のエラーをスローします。

[...] 
W20161109-03:53:42.862(1)? (STDERR) Error: The babel-runtime npm package could not be found in your node_modules 
W20161109-03:53:42.862(1)? (STDERR) directory. Please run the following command to install it: 
W20161109-03:53:42.863(1)? (STDERR) 
W20161109-03:53:42.863(1)? (STDERR) meteor npm install --save babel-runtime 
[...] 

を私が話したとbabel-runtimeパッケージをインストールしようとしています何。サーバーが正常に地面に降りることに成功するが、それは、その後、実行時に次のエラーをスローします。これはすべて、まだインストールされたり、コードを変更していない余分なパッケージで、新鮮に作成したプロジェクトをオフに取り組んでいる

Uncaught Error: Cannot find module 'babel-runtime/helpers/slicedToArray' 
at Function.require.resolve 

。私は解決策をオンラインで探してみましたが、修正されたバグの参照がたくさんありますが、何も見つかりませんでした。 StackOverflowの上(質問)のカップル[Babel - Error: Cannot find module 'babel-runtime/helpers/typeof'は次示唆している:NPMモジュールの再インストール

  1. のrm -rf node_modules 流星NPMは

  2. がNPM 流星NPM更新-g NPM

    の更新インストール

私はMeteor 1.4.2、NPM 3.10.9、Ubuntu 16.04.1を使用しています。

+0

これと同じです:/流星の最終更新日[email protected] => [email protected]更新しても全く動作しません:( –

+0

=> https://github.com/meteor /流星/問題/ 8032 –

答えて

6

私は同じ問題を抱えていました。少し掘削した後、この発見:(今朝11/9 1.4.2.1へのアップグレード後に当時と)1.4.2.1-rc.1にアップグレードした後https://github.com/meteor/meteor/issues/8019

* Installing the `babel-runtime` npm package in your application 
    `node_modules` directory is now required for most Babel-transformed code 
    to work, as the Meteor `babel-runtime` package no longer attempts to 
    provide custom implementations of Babel helper functions. 
Consider trying it out by using the latest release candidate (not officially released yet): 

meteor update --release 1.4.2.1-rc.1 
And then: 

meteor npm install --save babel-runtime 

を、エラーが解決されました。その後、

0

プロジェクトディレクトリ内package.jsonファイルを追加してみてくださいと 流星コマンドラインで

npm install --save babel-runtime

を実行します。

関連する問題