As instructed within the Setting up your development environment guidance material. https://docs.microsoft.com/en-us/sharepoint/dev/spfx/set-up-your-development-environment

I've installed yeoman:

npm install yo --global

I've reached the last step, to install the sharepoint generator:

npm install @microsoft/generator-sharepoint --global

I'm getting an error reported in the terminal.

npm ERR! Cannot read property 'pickAlgorithm' of null

  • Can you open command prompt and run npm list -g --depth=0? Can you share the output, please? Also, what version of node.js are you using? Oct 10 '21 at 23:54

During the installation of another package, I encountered the same problem, but the following command resolved it for me

npm cache clear --force

Downgrade your NPM version:

npm install -g npm@7.24.2 

This has worked for me.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.