Search code examples
aureliajspmmapbox-gl

Install mapbox-gl package via jspm failing


I am trying to add the mapbox gl package to my Aurealia Typescript skeleton using jspm. I am using the following command.

jspm install npm:mapbox-gl

This is what I am getting.

Looking up npm:mapbox-gl
Updating registry cache...
Downloading npm:[email protected]

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.

I am using jspm 0.16.36.

When I try to install the package via npm install mapbox-gl it works normally. Any suggestions?


Solution

  • Considering you are using jspm, you might also want to try and reference it through the GitHub repo rather than through npm:

    $ jspm install github:mapbox/mapbox-gl-js
    

    It works for me with jspm v16.x and v0.21.0 of MapboxGL.