I had also faced such error very recently. I can help you in fixing above error.
Let me tell you the reason behind this error is the pending subscription to your service worker for which your current application may be don’t have the source code (so you are facing 404).
So it clearly means that it is not related to your page fault.
I know that red lines are very annoying when you are stuck with it.
A very simple solution is to just unsubscribe by hand from a browser inspect page console:
So just to have the look at how many registrations are there you can use below command :
Now to remove first registration you can use below command:
I know my above solution will fix your errors and you can start working on your angular code.