1

I have installed the Viva connections extension in VS code. When I create a new project I get this error:

[2023-04-26T19:04:44.654Z] [INFO]
Running command: yo @microsoft/sharepoint --solution-name "vivasolution1" --component-type adaptiveCardExtension --aceTemplateType Basic --component-name "HelloWorld" --skip-install 
Error @microsoft/sharepoint --solution-name vivasolution1 --component-type adaptiveCardExtension --aceTemplateType Basic --component-name HelloWorld --skip-install 

You don't seem to have a generator with the name “@microsoft/sharepoint” installed.
But help is on the way:

You can see available generators via npm search yeoman-generator or via http://yeoman.io/generators/. 
Install them with npm install @microsoft/generator-sharepoint.

To see all your installed generators run yo --generators. Adding the --help option will also show subgenerators. 

If yo cannot find the generator, run yo doctor to troubleshoot your system.
[2023-04-26T19:08:38.346Z] [INFO]

But I do have it installed.

PS1> yo --generators
Available Generators:

  @microsoft/sharepoint
    adaptiveCardExtension
    applicationCustomizer
    commandSet
    component
    extension
    fieldCustomizer
    formCustomizer
    library
    searchQueryModifier
    solution
    webpart
PS1>

I have uninstalled and reinstalled the extension, no luck. Have not rebooted yet.

Not sure what to do with this?

5
  • Did you install it globally, like: npm install @microsoft/generator-sharepoint -g. Also, try restarting the system after installing npm packages and VS code extension. Apr 27, 2023 at 7:31
  • 1
    I did use the -g switch. I have not rebooted. brb
    – Josh Fu
    Apr 27, 2023 at 13:51
  • Reboot seems to have fixed it.
    – Josh Fu
    Apr 27, 2023 at 14:34
  • Great, glad it worked for you! Apr 27, 2023 at 14:47
  • I have added it as an answer below with some steps. Please Upvote(^) & accept as an Answer as it helped you & it will help others with similar question in future. Apr 27, 2023 at 14:48

1 Answer 1

0

Try below steps for resolve this issue:

  1. Install SPFx yeoman generator globally:

    Use below command:

    npm install @microsoft/generator-sharepoint -g
    
  2. Install Microsoft Viva Connections extension in Visual Studio code

  3. Restart your system and Visual studio code.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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