怎么改Meteor Velocity使用的iframe地址 [英] How do you change the iframe address used by Meteor Velocity

查看:41
本文介绍了怎么改Meteor Velocity使用的iframe地址的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用 Codio 进行 Meteor 开发,所以我的应用程序没有托管在 localhost:3000code> 当我预览它时,它实际上位于 random-name.codio.io:3000,我必须通过访问 random-name-3000.codio.io,所以当 Velocity 启动它的 iframe 来运行客户端测试时,它的地址是错误的,就像这样:<iframe src="http://localhost:5000/?mocha=true&amp;lastModified=1427105608181">.

I am using Codio for my Meteor development, so my app is not hosted at localhost:3000 when I'm previewing it, it's actually at random-name.codio.io:3000, which I have to get to by visiting random-name-3000.codio.io, so when Velocity fires up its iframe to run client-side tests on it has the wrong address, like so: <iframe src="http://localhost:5000/?mocha=true&amp;lastModified=1427105608181">.

我如何说服 Velocity 使用 random-name-5000.codio.io 作为它的 src 而不是 localhost:5000?

How do I convince Velocity to use random-name-5000.codio.io as its src instead of localhost:5000?

推荐答案

在运行应用程序时尝试这样的操作,我认为它没有正确设置应用程序 url 根目录:

Try something like this when running the app, i think it's not correctly setting the app url root:

ROOT_URL=http://random-name.codio.io:3000 meteor --port=3000

这篇关于怎么改Meteor Velocity使用的iframe地址的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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