Command 'ng serve --environment=prod' not working

$ ng version
Angular CLI: 15.2.7
Node: 18.16.0
Package Manager: npm 9.6.4

$ ng serve --environment=prod
Error: Unknown argument: environment

Found a fix, written an answer on github here: