Questions tagged [npm]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
53 views

issues Installing pnp/generator

I'm getting this error when I'm trying to install PnP/generator. Do anyone know how I can get passed this issue. I have the SharePoint generator installed already.
MALLIE WILLIAMS's user avatar
0 votes
1 answer
968 views

Cannot find module '@microsoft/sp-application-base' or its corresponding type declarations

I am working on spfx webpart and getting below error when trying to run my solution Cannot find module '@microsoft/sp-application-base' or its corresponding type declarations then i tried installing ...
Ashok 's user avatar
  • 49
0 votes
1 answer
194 views

PnP SharePoint Framework npm install issues

My organization is starting to really get into SharePoint development and I'm currently working on several projects related to SharePoint. I've really been getting into the SharePoint Framework ...
johnsoep's user avatar
0 votes
1 answer
764 views

"gulp serve --nobrowser" is raising this error "Task never defined: serve"

I am trying to run this command for my SPFx gulp serve --nobrowser,, but i am getting this error:- C:\Windows\System32>d: D:\>cd D:\Systems D:\Systems>gulp serve --nobrowser [13:23:37] ...
John John's user avatar
0 votes
0 answers
1k views

NPM version is not known to run on Node.js v10.15.1

I want to set-up the SPFx environment with the Node.js v10.15.1 and npm v6.4.1 so, I installed Node.js v10.15.1. But when I tried to check the npm version, it is showing the below error. How can I ...
Divya Sharma's user avatar
  • 1,463
0 votes
1 answer
28 views

Problem with library node SPFx

I have trouble downloading npm install @pnp/spfx-controls-react, has anyone happened to it? It shows me the following error, I have removed and installed node again, but the problem persists
elsa's user avatar
  • 101
0 votes
1 answer
350 views

npm install command error

Sample:(PS: You can find what I tested in the GitHub link below) https://github.com/pnp/sp-dev-fx-webparts/blob/master/samples/react-mgtEvents/src/webparts/mgtEvents/MgtEventsWebPart.ts Problem: Hello,...
Roberto Hajj's user avatar
0 votes
1 answer
3k views

gulp build is raising this Error - [tslint] Error: Cannot find module '@microsoft/rush-stack-compiler-3.2'

I want to install this web part from hhttps://github.com/AsishP/SPFxWebParts , but when i run this command gulp build i got this error Error - [tslint] Error: Cannot find module '@microsoft/rush-stack-...
John John's user avatar
0 votes
2 answers
9k views

npm install outputs an error: npm ERR! Cannot read property 'pickAlgorithm' of null

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 ...
Sideburnt's user avatar
3 votes
3 answers
507 views

Share "node_modules" folder between webparts

Here is my scenario: I have 7 different webparts In order to have more control over the projects, I have split them in different projects All of the projects were created using the Yeoman installer ...
JohnRambo's user avatar
  • 187
1 vote
1 answer
153 views

SPFx Yeoman generates wrong package versions

In the past I have generated SPFx projects successfully using @microsoft/generator-sharepoint yeoman generator, but now it is not giving me the same versions for the SPFx packages. I discovered it was ...
Jpw84's user avatar
  • 33
1 vote
1 answer
477 views

SPFx development - npm audit vulnerabilities

The company I work for needs custom web parts in modern SharePoint. I was humming along following the excellent (Microsoft's sponsored) tutorials on SPFx development. I got my web part working on my ...
Miryam's user avatar
  • 13
0 votes
1 answer
28 views

The 'npm outdated -g' current is not the same as my 'npm -v' [closed]

My npm -v is 6.13.4 but my current in npm outdated -g is 6.11.3. How would I remedy that issue?
Lance Bitner's user avatar
4 votes
4 answers
11k views

Property 'web' does not exist on type 'SPRest'

I installed these packages: @pnp/logging @pnp/common @pnp/odata @pnp/sp npm i @pnp/logging @pnp/common @pnp/odata @pnp/sp --save and tried this: import { sp } from '@pnp/sp'; public ...
bAbdenour's user avatar
  • 164
1 vote
1 answer
3k views

How to fix error cannot find module @microsoft/sp-build-web.When trying the sp-dev-ebpart samples

I have been trying to build the https://github.com/SharePoint/sp-dev-fx-webparts I have gone through the instructions and reinstalled and installed but no luck I am now getting the error: Cannot ...
naijacoder's user avatar
  • 4,226
0 votes
1 answer
614 views

How to setup the environment for the sample sp-dev-fx-webparts - client-side web part samples

I have installed git and cloned the below https://github.com/SharePoint/sp-dev-fx-webparts/tree/master/samples Installed node and NPM for windows.Ran npm install for just one specific folder (react-...
naijacoder's user avatar
  • 4,226
1 vote
1 answer
214 views

Got the error in SPFx installation "Yeoman Doctor - Running sanity checks on your system"

Hi All, When I tried to installed the SPFx "npm install -g yo" getting the issues. Tried both "npm install -g yo@latest" and "npm rm -g yo", "npm install -g yo" but it didn't help. Attached the ...
Mohammad Tahir's user avatar
2 votes
0 answers
192 views

Excessive Vulnerability Count in Yeoman SharePoint Generator

When I run yo @microsoft/sharepoint and pick standard options for a SharePoint Online WebPart with No JavaScript framework, NPM shows 1956 vulnerabilities with 140 of them being high priority. I ...
Shawn Eary's user avatar
4 votes
1 answer
347 views

Sharepoint framework (spfx) failes to create new project

I use yo @microsoft/sharepoint and it hangs at `Found npm version 6.5.0,no error the console is not closing it just stops. (files are not produced and multiple enters don't do anything) Guys do you ...
kolek's user avatar
  • 261
2 votes
0 answers
42 views

Working with npm packages in SharePoint hosted app

I am starting to work on a SP 2013 hosted app. I am planning to use typescript and have setup my project with Typescript configurations enabled. I have created a SP module called "dist" and all ...
Unnie's user avatar
  • 8,809
2 votes
1 answer
5k views

Updating SPFX breaks gulp

So i tried installing a webpart from scratch & added React as a framework. All good, but the version of @microsoft dependencies is 1.5.1 AND the latest is actually 1.6.0. I've tried updating ...
Dante R.'s user avatar
  • 569
1 vote
3 answers
866 views

ts Cannot find the module

I am very new to the SPFx I just started. I was making my first web part in Visual Studio Code but I was having some difficulty in my code. May be somebody can help. I have scss module in the same ...
Milind's user avatar
  • 1,538
1 vote
5 answers
16k views

Local gulp not found when executing gulp serve

I have downloaded the spfx samples from github and I am running into this problem when I execute gulp serve. λ gulp serve [12:39:37] Local gulp not found in C:\react-todo-basic [12:39:37] Try running:...
Burre Ifort's user avatar
  • 1,318
0 votes
2 answers
571 views

SharePoint 2016 On Premise Dev using SharePoint Framework

This is my first question in this forum ;) I need to develop SharePoint 2016 On Premises solution in Visual Studio using the SharePoint Framework. i did some RnD over it and found a nice articles on ...
Happy Coding's user avatar
4 votes
0 answers
162 views

Use npm to reuse react components between web parts

I've been building web parts for a while now and I've found myself copy-pasting some of my spfx react components more often than I'd like. The ideal solution for me here would be to publish the ...
Alexandre Savard's user avatar
3 votes
2 answers
8k views

pnp.sp.site.getWebUrlFromPageUrl method is returning wrong web URL

I am using sp-pnp-js for my spfx project. GetWebUrlFromPageUrl method is returning wrong URL that includes sitePages also. Please refer: my current page location is https://xxxx.sharepoint.com/sites/...
DvG's user avatar
  • 2,332
1 vote
1 answer
123 views

Issue setting up spfx project

I am not able to generate a yo project using @microsoft/generator-sharepoint. The menu simply freezes at the following step - which type of client-side component to create? arrows key don't work ...
Swayam Siddha's user avatar