The issue I ran into is that using shallow routing causes the progressbar to appear even with the showOnShallow option set to false. The main problem is that Next.js 12.2 fires the routeChangeError event unnecessarily. I have already reported it on their repo, but this also surfaced an issue with this component. The routeChangeError has a different function signature than routeChangeComplete, meaning the shallow routing flag gets ignored and the progressbar gets display even with showOnShallow set to false.
The issue I ran into is that using shallow routing causes the progressbar to appear even with the
showOnShallow
option set to false. The main problem is that Next.js 12.2 fires therouteChangeError
event unnecessarily. I have already reported it on their repo, but this also surfaced an issue with this component. TherouteChangeError
has a different function signature thanrouteChangeComplete
, meaning the shallow routing flag gets ignored and the progressbar gets display even withshowOnShallow
set to false.I found a previous mention of this issue here: https://github.com/apal21/nextjs-progressbar/issues/70#issuecomment-1061533686, but it looks like it has not been fixed yet.