我正在关注本教程:http://elixir-lang.org/getting-started/mix-otp/agent.html
所以在我的Elixir项目中,我有一个模块lib/kv/bucket.exs,并对它进行测试test/kv/bucket_test.exs.
当我运行混合测试时,我收到以下错误:** (UndefinedFunctionError) undefined function KV.Bucket.start_link/0 (module KV.Bucket is not available)我错过了什么?
我正在尝试使用PDF.js 1.0.571查看S3存储桶上托管的PDF。但是,出现以下错误:

类似问题的有效 JSBin :http : //jsbin.com/pdfjs-helloworld-v2/7086/edit
不起作用的JSBin:http : //jsbin.com/pdfjs-helloworld-v2/10562/edit
我的S3 CORS设置:

用于测试的S3 PDF:http://sheethub.s3.amazonaws.com/sheets/0b26b42aa027c6b73855feb68b8c089e893f8114/original/another_guldove.pdf?1407157315
我的CORS设置错误吗?我在这里想念什么?http://sheethub.s3.amazonaws.com和http://s3.amazonaws.com/sheethub之间有区别吗?
我是谷歌地图的新手.我正在尝试转动用户输入的坐标,将我在地图上的标记移动到那些坐标.例如,如果用户输入50.75,74.1,则标记将平移到该坐标.不幸的是,我无法让它发挥作用.这是我的功能:
function moveMarker() {
var Markerloc = document.getElementById("Markerloc").value;
var newLatlng = new google.maps.LatLng(Markerloc);
marker.setPosition(newLatLng)
}
Run Code Online (Sandbox Code Playgroud)
这是我的HTML代码:
<input type="text" id= "Markerloc" value="Paste your coordinates" />
<input type="button" onclick="moveMarker()" value="Update Marker">
Run Code Online (Sandbox Code Playgroud)
编辑:我认为这是解决它,但不知何故,它仍然无法正常工作.
这是我的代码:
<script type="text/javascript">
var map;
var zoomLevel;
function initialize(){
var myLatlng = new google.maps.LatLng(40.65, -74);
var myOptions = {
zoom: 2,
center: myLatlng,
mapTypeId: google.maps.MapTypeId.ROADMAP,
}
var map = new google.maps.Map(document.getElementById('map_canvas'), myOptions);
var zoomLevel = map.getZoom();
var marker = new google.maps.Marker({
position: myLatlng,
map: map,
draggable: true
});
// Update …Run Code Online (Sandbox Code Playgroud) 我想在运行时使用 Node.js 执行 ES6 代码。给定一串代码:
const es6code = 'const square = (b) => { return b * b; }';
es6Eval(es6code)(5)
Run Code Online (Sandbox Code Playgroud)
该es6Eval函数会将 es6 转换为 es5 并在运行时评估代码。
我该怎么做呢?
我似乎无法定义for循环函数,我做错了什么?
我的HTML代码:
<body onload="generate()">
Run Code Online (Sandbox Code Playgroud)
我的Javascript代码:
function generate(){
for(i = 0; i < 150; i++) {
document.write("<div></div>");
}
};
Run Code Online (Sandbox Code Playgroud) javascript ×4
amazon-s3 ×1
babeljs ×1
cors ×1
ecmascript-6 ×1
elixir ×1
elixir-mix ×1
google-maps ×1
html ×1
maps ×1
node.js ×1
pdf ×1
pdf.js ×1
transpiler ×1