I have recently updated Powershell to 7.1.3
Then I started to notice something odd in the terminal inside VS Code which essentially is running the same Powershell I just updated. Between two different project directories, one I can run node but the other does not recognise node as a command. I print $env:Path and it gives different output. The one that doesn't recognised the node command seems to be concatenation of multiple path variables.
So, for it to work in that particular directory, each time I have to run
$env:Path = [System.Environment]::GetEnvironmentVariable("Path","Machine")
This is so odd. It was working fine until I updated Powershell. Anyone can shed some light here?