I wish to include my custom flag (-t example) when executing the nx angular serve command.
However, I encounter an error from nx indicating:
't' is not found in schema
I intend to intercept this flag within proxy.mjs and handle it accordingly.
What steps should I take to pass this argument without encountering an error?
You can pass environment variables to
ng serveusingENV t=xxxwherexxxis the value you want.You can then retrieve the value via
process.env:For multiple variables, you just use multiple
ENVcommands:Then logging would be the same: