react-map-gl
react-map-gl copied to clipboard
Dependency warning for @mapbox/mapbox-gl-traffic
trafficstars
Since I added urbica/react-map-gl to my app, I get this npm warning:
@mapbox/[email protected] requires a peer of mapbox-gl@^0.29.0 but none is installed. You must install peer dependencies yourself
However, the package itself depends on >= 0.40.0:
https://github.com/urbica/react-map-gl/blob/master/package.json#L49
and I am using ^1.6.0 which works. How can I get rid of the warning caused by mapbox-gl-traffic, which is an optional dependency?
In NPM 7 this causes a peer dependency error and requires use of the --force or --legacy-peer-deps flag.