How do your upgrade a package in your app

The way I did it was to rm elm.json && elm init, then repeat this process:

elm make
#fix compilation errors from http 2.0.0 if you've arrived at that point
elm install <the thing make fails on>

This way, when I came to elm install elm/http, there was nothing in elm.json that would prevent it from choosing the newest version.

This process does imply that you’re updating all your dependencies to the latest version, not just one particular dependency. But one could imagine a slightly more complex variation on it that would focus on a single upgrade, something like:

elm make
#if you're at or beyond the point of errors about http then:
    #fix compilation errors from http 2.0.0 if you've arrived at that point
    elm install <the thing make fails on>
#else
    #manually restore the line in elm.json that make failed on
1 Like