The following flag is availble in Chrome and Edge, and thus likely Chromium products in general:
chrome://flags/#unsafely-treat-insecure-origin-as-secure
In the text field, you should be able to add each of your localhost origins to treat them as secure:
http://localhost,http://127.0.0.1,http://[::1]
Tested on Chrome 136 and Edge 136, the current latest stable versions. Feedback is appreciated.