我正在尝试使用jspm
将mapbox gl包添加到我的Aurealia Typescript skeleton。我使用以下命令。
jspm install npm:mapbox-gl
这就是我得到的。
Looking up npm:mapbox-gl
Updating registry cache...
Downloading npm:mapbox-gl@0.19.1
warn Error on processPackageConfig
Package.json dependency mapbox-gl-shaders set to github:mapbox/mapbox-gl-shaders#e4737bb136d718f9c5fe8d943380f05db6249b57, which is not a valid dependency format for npm.
It's advisable to publish jspm-style packages to GitHub or another registry so conventions are clear.
warn Error processing package config for npm:mapbox-gl.
err Error processing package config for npm:mapbox-gl.
warn Installation changes not saved.
我正在使用jspm 0.16.36
。
当我尝试通过npm install mapbox-gl
安装软件包时,它可以正常工作。有什么建议吗?
答案 0 :(得分:0)
考虑到你正在使用jspm,你可能也想尝试通过GitHub repo而不是通过npm来引用它:
$ jspm install github:mapbox/mapbox-gl-js
它适用于jspm v16.x和v0.21.0 of MapboxGL。