JS解析shapefile(.shp)

参考资料:http://jjxliu306.iteye.com/blog/2424894

<!DOCTYPE html>
<script src="https://unpkg.com/[email protected]"></script>
<script>

shapefile.open("../../data/天津.shp")
  .then(source => source.read()
    .then(function log(result) {
      if (result.done) return;
      console.log(result.value);
      return source.read().then(log);
    }))
  .catch(error => console.error(error.stack));
 
</script>

控制台输出结果:

猜你喜欢

转载自blog.csdn.net/qq_18144905/article/details/81982279
今日推荐