Skip to main content

Questions tagged [spfx-webparts]

Technical questions about building and using web parts based on the SharePoint Framework client-side development model.

Filter by
Sorted by
Tagged with
7 votes
4 answers
28k views

How to retrieve pageContext in SPFx?

I'm following the second tutorial from the SharePoint Framework dev center: Connect to SharePoint It states that you can retrieve details from this.context.pageContext, however this is no longer the ...
DivXZero's user avatar
  • 173
5 votes
3 answers
6k views

SharePoint Framework web parts - dynamic properties pane

I was playing around with the SharePoint framework and I was trying to get the web part to load SharePoint lists via a promise. First I noticed that await and async are not supported (probably due to ...
Kiril Iliev's user avatar
1 vote
1 answer
6k views

SPFx R.C. post method, SPHttpClient.configurations.v1 undefined exception

I am try to convert this old school example. It was drop 3, now I need to convert it to SPFx RC version; private createItem(): void { this.getListItemEntityTypeName() .then((...
TyForHelpDude's user avatar
1 vote
1 answer
3k views

How do I pass HTML table inside mailto in anchor tag?

I am creating a web part in SharePoint Online using SPFx REACT framework and I want to open an email pop up with an HTML table in the body section of the email. Currently, I am using mailto to open an ...
user20815589's user avatar
5 votes
1 answer
3k views

SharePoint Framework: how to change TypeScript version used by gulp?

I set up a new project using the yeoman template for SharePoint Framework web parts. Everything is working fine, I can run gulp serve and work in the local workbench. Good. Now I need to change the ...
Heinrich Ulbricht's user avatar
4 votes
1 answer
923 views

How to Provision Workflows with SharePoint Framework

I'm shifting my development to SharePoint framework now and have met with this problem. How do I deploy/provision a workflow to SharePoint Online using SharePoint Framework Client Web part. I couldn'...
Thi Vo's user avatar
  • 364
3 votes
3 answers
10k views

Customize master page on modern/communication site

I know that with the SharePoint Online publishing site we can develop a site where we can have the exact layout of my designed mock-up. So my question is will we be able to customize on some of the ...
user71767's user avatar
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
0 answers
466 views

How do you delete tasks from Project Server via REST?

March 2 2023 - Extremely late after-the-fact update: I got a follow up question to this (posted as an answer, so it's going to be removed) as to whether or not this ever got resolved. For posterity: ...
Dylan Cristy's user avatar
  • 12.7k
0 votes
3 answers
10k views

Customizing the PnP people search handlebar template in SharePoint online

I am using the modern PnP SPFx people search web part - and for the people search below is the out of the box template is generated by the web part: <content id="template"> <style> ...
SP 2022's user avatar
  • 4,084
25 votes
4 answers
3k views

Will the new SharePoint FrameWork increase speed?

I don't have a benchmark but it seems to me SharePoint Online is getting slower. This is a fresh new SPOnline Tenant, (News) images being pulled from a Picture Library Is it me or is this just super ...
Danny '365CSI' Engelman's user avatar
13 votes
1 answer
9k views

Options for elevating permissions in SharePoint Framework

Background I have a site which will have a number of Lists and a Document Library deployed as part of an SPFx application. The Document Library will have a folder hierarchy which must be strictly ...
Mike Insch's user avatar
8 votes
1 answer
1k views

Apps added to App Catalog not available for installation on other sites

I started with SPFx development recently. I packaged a client side web-part as a file helloworld-webpart.sppkg following Microsoft's tutorial. Then I uploaded it to my Apps Catalog site. Though it was ...
mohd tahir's user avatar
  • 2,406
8 votes
3 answers
3k views

Run development and production versions of the SP Fx web parts in two different site collections?

Currently, the SharePoint Framework solutions are deployed as tenant wide app packages. Thereby, all instances of the web parts refer the JavaScript files from the CDN location specified in the ...
user2560429's user avatar
7 votes
1 answer
4k views

SPFx webpart not updating with latest spkg uploaded

My Spfx spkg uploads successfully to the apps catalog. Tenant wide upload is enabled. When I do 'Add an App', This app is not available for installation under 'From your Organisation' Although when ...
mohd tahir's user avatar
  • 2,406
6 votes
1 answer
3k views

SPFx Replacement for Script Editor Web Part

So I was having a play around with the new Modern Experience site pages and while it's pretty slick and looks great (as well as fixing the issues with container layouts being a royal pain to change ...
Thomas Gass's user avatar
  • 1,308
6 votes
2 answers
6k views

How to get Termset using the new SharePoint framework SPFx

I am new to to Typescript, watched videos and created the sample application of client webpart using new SharePoint development framework. All sample application worked well, and using Rest Queries i ...
vinit kumar's user avatar
6 votes
1 answer
2k views

Update list in SharePoint framework - SPFx app

i have created list and columns in SPFx app using elemets.xml and schema.xml. Now after doing this i want to add new column to already created list. I have created elements-v2.xml and upgrade-actions-...
Saad Zulfiqar's user avatar
5 votes
1 answer
6k views

How to display the SharePoint "Live Persona Card"?

In our SharePoint Framework web parts we want to show people information just like SharePoint does: When hovering over the name or image of somebody a popup like this should open. Looking at the ...
Heinrich Ulbricht's user avatar
5 votes
1 answer
5k views

What is difference between SharePoint Framework (SPFx) Extensions and SharePoint Framework (SPFx) Web PART

I have started working on SharePoint Online. Where I have to use SPFX. What is the Difference between SharePoint Framework (SPFx) Web Part and SharePoint Framework (SPFx) Extensions
Akshay Dattatray Nangare's user avatar
5 votes
3 answers
11k views

NodeJS not compatible

when I run gulp serve I get the following error. Your dev environment is running NodeJS version v10.15.0 which does not meet the requirements for running this tool. This tool requires a version of ...
user1339913's user avatar
4 votes
2 answers
927 views

Add an SPFx WebPart from an SPFx Extension on a modern site

Within our product we have created an SPFx extension to show a navigation component on the top of our modern pages. Additional to this navigation component we want to show a button which opens an ...
pkmelee337's user avatar
4 votes
2 answers
669 views

SPFx Creating custom sectionlayout

Is it possible to create a modern UI section layout? e.g. a tab layout
Philip Szalla's user avatar
4 votes
4 answers
439 views

SharePoint Framework web parts - do you need a developer tenant?

I want to test my SharePoint Framework web part in Office 365, in SharePoint Online. Therefore I upload the .sppkg file to the App Catalog. Unfortunately SharePoint says my app package is invalid: ...
Heinrich Ulbricht's user avatar
3 votes
2 answers
3k views

Add files to subfolders using rest api in javascript

What is working right now is i can upload to the root folder of a library using the code below : myDropzone.options.url = `${_context.pageContext.web.absoluteUrl}/_api/web/Lists/getById('${_parent....
Keshav Taurah's user avatar
3 votes
2 answers
9k views

Get current user's user group in SPFx WebPart

How can I get the sharepoint groups the current user is a part/ belogns to, without @pnp/sp js framework in SPFx ?
user10000's user avatar
  • 163
3 votes
3 answers
2k views

How I can upload a App from Sharepoint Framework?

I am trying to upload a app generate with SharePoint Framework to the App Catalog of my SharePoint, but when I upload it, it don't recognize how a valid package and I can't add this app to my ...
Jesús Velasco López's user avatar
3 votes
4 answers
3k views

Add jQuery in Client Web part (SPFX)

I am following a tutorial from Microsoft docs and trying to import jQuery files into my client web part but getting error. https://docs.microsoft.com/en-us/sharepoint/dev/spfx/web-parts/get-started/...
Ali's user avatar
  • 913
3 votes
1 answer
1k views

Any Api's to get Last Opened Documents

Do we have any Apis to get the Last Opened Documents That is displayed in the the Office 365 Home Page. Intention is to get the list of the last opened Documents using SpFx webpart.
Jaj's user avatar
  • 95
2 votes
1 answer
2k views

Getting warning messages : Warning - [sass] The local CSS class 'min-chart' is not camelCase and will not be type-safe

I am using third party css in SPFx. When I am building it, SPFx is showing me lots of warning messages : I am using Windows 10 / SPFx 1.11.0. Please let me know how to disable these warning messages. ...
Gaurav Goyal's user avatar
2 votes
1 answer
2k views

SharePoint workbench not reflecting changes

I'm building a SharePoint SPFx react web app. I've been using workbench for the last few weeks and it's been great. However, today when I did gulp serve I noticed that my changes are no longer being ...
hisusu32's user avatar
2 votes
1 answer
11k views

SPFX: How to add item in SharePoint list with attachment?

I have created a SPFX webpart to add item in list with attachment. How to add item with attachment ?
Ronak Patel's user avatar
  • 3,251
2 votes
2 answers
2k views

Can a user update a SharePoint list using SPFx without the user having access to the list?

In C# you could allow users to access a SharePoint list they have no access to by using SPSecurity.RunWithElevatedPrivileges(delegate () .....etc. Is there a way achieving the same functionality ...
Nigel Price's user avatar
2 votes
1 answer
2k views

How to apply a theme to a spfx web part?

I have a spfx web part the gets and displays list items. I'm not sure how to apply a theme to this web part so that the font type and style of the web part title and list items match the rest of the ...
chris rowles's user avatar
2 votes
2 answers
1k views

Typescript errors in SharePoint Framework webparts

I created a new sharePoint framework webpart using the msdn link https://dev.office.com/sharepoint/docs/spfx/web-parts/get-started/build-a-hello-world-web-part After Executing the gulp serve ...
TARUN's user avatar
  • 2,856
1 vote
1 answer
923 views

How can I implement Angular 2 routing in an SPFX webpart

How can I use Angular 2 in SPFX? I appreciate its not out of beta quite yet but I have found it to be excellent for 'larger' apps. Especially RC5 which provides a new ngModule decorator. Using this ...
Sebastian Rogers's user avatar
1 vote
0 answers
1k views

"setState(...): Can only update a mounted or mounting ..." error in web part

I have a web part running works fine and I added new one. It only read items from the list. But before get there, there is an error in browser; "setState(...): Can only update a mounted or mounting ...
TyForHelpDude's user avatar
1 vote
2 answers
1k views

spfx webpart/component with position: fixed

I'm trying to create a spfx-react webpart for SharePoint Online like the feedback button on the walmart page (https://www.walmart.com right side). This works in edit mode and in the workbench (local ...
sebastian.do's user avatar
1 vote
1 answer
321 views

Are there any dependencies for PS.js (Project Server JSOM)?

Because I can't seem to do what I need to get done using the REST API, I am going to try to use the Project Server JSOM in an SPFx webpart. I found instructions on how to load the SharePoint JSOM ...
Dylan Cristy's user avatar
  • 12.7k
1 vote
1 answer
2k views

Grant permissions to all external users on Client Side Assets library in App Catalog site

I have a SPFx web part added to my page in a modern SharePoint site. External Sharing is enabled in my modern site and I need to grant at least "Read" permissions to every external user on "Client ...
Crow Canyon's user avatar
1 vote
2 answers
862 views

SPFx Retrieve lists using SharePoint REST API

I am trying to create a web part to deploy to SharePoint Online. Following this Connect your web part to SharePoint. When I add the code below. I receive the errors below. Do you have to have Office ...
Fishcat's user avatar
  • 11
1 vote
1 answer
1k views

Sharepoint Online every SPFx web parts get this error : Something went wrong -> Mismatched anonymous define() module

I have SharePoint online sites and some spfx web parts. These sites are created with publishing site templates and web parts have been working for months. I rarely got this error "something went ...
Nuri Durmuş's user avatar
1 vote
1 answer
858 views

Error when displaying HelloWorld web part in tenant workbench

My HelloWorld web part works fine in my localhost workbench. On my tenant workbench, I can add the web part but then I get the attached error instead of displaying it.
Tracy's user avatar
  • 667
1 vote
1 answer
2k views

SPFx Unable to use 'fs' module

I am creating a SPFx web part which is using fs module, but getting error Error: Can't resolve 'fs'. I know this issue causing from typescript because of missing typings. Following is the exact error ...
ThinkB4Code's user avatar
  • 2,970
0 votes
2 answers
1k views

From Azure Function (secured by AAD), how to properly detect the caller (the end-user of SPFx WebPart) through the AadHttpClient?

Note: Both Azure Function and the SPFx WebPart mentioned below are written in NodeJS/JavaScript. None of them are in C#. I have an Azure Function (secured by AAD: App Registration) which is being ...
夏期劇場's user avatar
0 votes
1 answer
797 views

how to get data from responseJSON

I am trying below code but always get undefined in console for console.log(responseJSON.Title); this.props.context.spHttpClient.get(`https://someazuresite.azurewebsites.net/api`, SPHttpClient....
kumar's user avatar
  • 139
0 votes
2 answers
370 views

How to build a CAML query from a string of data in JavaScript?

I have a string 'listOfUsers' which is in the format user1;user2;user3;user4;user5;user6; This string could have any number of users. I would like to build a CAML query which will find all those users....
Pete Whelan's user avatar
0 votes
2 answers
2k views

SPFx: pnp.sp.search how to get only list items

I made search in SPFx, now i need to display only list items. My code example: pnp.sp.search({ Querytext: query, RowLimit: 20, StartRow: 0, QueryTemplate: "...
Ann's user avatar
  • 51
0 votes
1 answer
577 views

Updating Client Side Web App in Sharepoint Online App Library - Not Updating

I have an app deployed on Sharepoint with 3 Client Side Web Parts. When i first add it, it's version is = 1.0.0.0. When I make changes to the solution: Change version to 2.0.0.0 gulp bundle --ship ...
rsnyder's user avatar
  • 103
0 votes
1 answer
382 views

How to change web description in SPFx React webpart?

I'm writing an SPFx web part using React. I can get the description of the current web like this: let desc = this.props.context.pageContext.web.description; But how can I change the web description? ...
Papageno's user avatar
  • 343