I had this same issue when I was starting out and all I had done was miss the starting @ off the package name.
So npm -i primeng
this caused the forced github login prompt
But npm -i @primeng
This was what I meant to type and worked as expected but because I was a n00b I didn't notice I'd missed off the @ symbol.
So....