gpt4 book ai didi

javascript - Meteor simple-todos tut - 第 2 步 - Uncaught Error 找不到模块 './template.body.js

转载 作者:塔克拉玛干 更新时间:2023-11-02 22:21:50 25 4
gpt4 key购买 nike

我创建了一个 debian 虚拟机,并在其中安装了 meteor 版本 1.4.2。

我正在研究 simple-todos meteor 教程,blaze view。

我已经完成了第 2 步的所有操作[多次;甚至删除并重新开始多次];我什至将所有代码直接 c&p 到各种文件中。我花了几个小时搜索谷歌; git-hub 和 stackoverflow 并没有发现任何似乎与我的问题有关的东西。

当我在浏览器中查看应用程序时,页面是空白的...当我在控制台中查看时,出现以下错误代码:

Uncaught Error: Cannot find module './template.body.js'
at require (http://localhost:3000/packages/modules-runtime.js?hash=ab7e8d32b6c7b5a5fa7ae1b65e8225c4f9e30223:119:19) [this error continues with a lot more references and hashes, but I can't post more than 2 links]

如果有人至少能为我指出正确的方向,以便我可以继续研究这个问题,我将不胜感激。

最佳答案

好吧,这很奇怪......我复制了你所看到的。当您在执行此编码时有 meteor RUNNING 时会发生这种情况,因此它正在进行实时代码更新,但模块未正确构建/包含。

我所做的只是停止并重新启动 Meteor。它奏效了。

不确定为什么它不在重建和热代码推送中加载模块,但你已经找到了,这就是修复。

这是我的 shell,所以你可以看到我做了什么:

shaunst:~/workspace $ curl https://install.meteor.com/ | sh
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 7784 0 7784 0 0 23942 0 --:--:-- --:--:-- --:--:-- 23950
Downloading Meteor distribution
######################################################################## 100.0%

Meteor 1.4.2 has been installed in your home directory (~/.meteor).
Writing a launcher script to /usr/local/bin/meteor for your convenience.
This may prompt for your password.

To get started fast:

$ meteor create ~/my_cool_app
$ cd ~/my_cool_app
$ meteor

Or see the docs at:

docs.meteor.com

shaunst:~/workspace $ meteor create simple-todos
Created a new Meteor app in 'simple-todos'.

To run your new app:
cd simple-todos
meteor

If you are new to Meteor, try some of the learning resources here:
https://www.meteor.com/learn

shaunst:~/workspace $ cd simple-todos/
shaunst:~/workspace/simple-todos $ meteor npm install
simple-todos@ /home/ubuntu/workspace/simple-todos
└─┬ meteor-node-stubs@0.2.3
├── assert@1.3.0
├─┬ browserify-zlib@0.1.4
│ └── pako@0.2.8
├─┬ buffer@4.5.1
│ ├── base64-js@1.1.2
│ ├── ieee754@1.1.6
│ └── isarray@1.0.0
├─┬ console-browserify@1.1.0
│ └── date-now@0.1.4
├── constants-browserify@1.0.0
├─┬ crypto-browserify@3.11.0
│ ├─┬ browserify-cipher@1.0.0
│ │ ├─┬ browserify-aes@1.0.6
│ │ │ ├── buffer-xor@1.0.3
│ │ │ └── cipher-base@1.0.2
│ │ ├─┬ browserify-des@1.0.0
│ │ │ ├── cipher-base@1.0.2
│ │ │ └─┬ des.js@1.0.0
│ │ │ └── minimalistic-assert@1.0.0
│ │ └── evp_bytestokey@1.0.0
│ ├─┬ browserify-sign@4.0.0
│ │ ├── bn.js@4.11.1
│ │ ├── browserify-rsa@4.0.1
│ │ ├─┬ elliptic@6.2.3
│ │ │ ├── brorand@1.0.5
│ │ │ └── hash.js@1.0.3
│ │ └─┬ parse-asn1@5.0.0
│ │ ├─┬ asn1.js@4.5.2
│ │ │ └── minimalistic-assert@1.0.0
│ │ ├─┬ browserify-aes@1.0.6
│ │ │ ├── buffer-xor@1.0.3
│ │ │ └── cipher-base@1.0.2
│ │ └── evp_bytestokey@1.0.0
│ ├─┬ create-ecdh@4.0.0
│ │ ├── bn.js@4.11.1
│ │ └─┬ elliptic@6.2.3
│ │ ├── brorand@1.0.5
│ │ └── hash.js@1.0.3
│ ├─┬ create-hash@1.1.2
│ │ ├── cipher-base@1.0.2
│ │ ├── ripemd160@1.0.1
│ │ └── sha.js@2.4.5
│ ├── create-hmac@1.1.4
│ ├─┬ diffie-hellman@5.0.2
│ │ ├── bn.js@4.11.1
│ │ └─┬ miller-rabin@4.0.0
│ │ └── brorand@1.0.5
│ ├── inherits@2.0.1
│ ├── pbkdf2@3.0.4
│ ├─┬ public-encrypt@4.0.0
│ │ ├── bn.js@4.11.1
│ │ ├── browserify-rsa@4.0.1
│ │ └─┬ parse-asn1@5.0.0
│ │ ├─┬ asn1.js@4.5.2
│ │ │ └── minimalistic-assert@1.0.0
│ │ ├─┬ browserify-aes@1.0.6
│ │ │ ├── buffer-xor@1.0.3
│ │ │ └── cipher-base@1.0.2
│ │ └── evp_bytestokey@1.0.0
│ └── randombytes@2.0.3
├── domain-browser@1.1.7
├── events@1.1.0
├─┬ http-browserify@1.7.0
│ ├── Base64@0.2.1
│ └── inherits@2.0.1
├── https-browserify@0.0.1
├── os-browserify@0.2.1
├── path-browserify@0.0.0
├── process@0.11.2
├── punycode@1.4.1
├── querystring-es3@0.2.1
├─┬ readable-stream@2.0.6
│ ├── core-util-is@1.0.2
│ ├── inherits@2.0.1
│ ├── isarray@1.0.0
│ ├── process-nextick-args@1.0.6
│ └── util-deprecate@1.0.2
├─┬ stream-browserify@2.0.1
│ └── inherits@2.0.1
├── string_decoder@0.10.31
├── timers-browserify@1.4.2
├── tty-browserify@0.0.0
├─┬ url@0.11.0
│ ├── punycode@1.3.2
│ └── querystring@0.2.0
├─┬ util@0.10.3
│ └── inherits@2.0.1
└─┬ vm-browserify@0.0.4
└── indexof@0.0.1

shaunst:~/workspace/simple-todos $ meteor --port 8080
[[[[[ ~/workspace/simple-todos ]]]]]

=> Started proxy.
=> Started MongoDB.
=> Started your app.

=> App running at: http://localhost:8080/
=> Meteor server restarted
=> Meteor server restarted
=> Meteor server restarted
=> Meteor server restarted
=> Client modified -- refreshing (x3)
=> Meteor server restarted
=> Meteor server restarted
=> Client modified -- refreshing^C
shaunst:~/workspace/simple-todos $ ^C
shaunst:~/workspace/simple-todos $ meteor --port 8080
[[[[[ ~/workspace/simple-todos ]]]]]

=> Started proxy.
=> Started MongoDB.
=> Started your app.

=> App running at: http://localhost:8080/
=> Client modified -- refreshing (x2)

关于javascript - Meteor simple-todos tut - 第 2 步 - Uncaught Error 找不到模块 './template.body.js,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40295188/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com