Error: error:0308010C:digital envelope routines::unsupported

When

Occurs when running npm i on older Angular applications.

Solution

// powershell
$env:NODE_OPTIONS="--openssl-legacy-provider"

Update global npm packages

// Updating all globally-installed packages
npm update -g
// or 
npm install npm@latest -g

// Determining which global packages need updating
npm outdated -g --depth=0

// Updating a single global package
npm update -g <package_name>

ref