yo Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'stream' imported

Juan Carlos Rivero 0 Reputation points
2024-05-28T21:04:11.98+00:00

when I run

yo

or yo @microsoft/sharepoint on powershell or cmd I get

Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'stream' imported

SharePoint Development
SharePoint Development
SharePoint: A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.Development: The process of researching, productizing, and refining new or existing technologies.
2,783 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. RaytheonXie_MSFT 33,176 Reputation points Microsoft Vendor
    2024-05-29T06:26:08.17+00:00

    Hi @Juan Carlos Rivero,

    You will need to check the version of node. Please update the node.js to latest version. You could refer to following script to update the version

    Install-Module -Name power-nvm
    Add-Type -AssemblyName System.IO.Compression.FileSystem
    nvm install latest
    nvm default latest
    

    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.