Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [spfx-webparts]

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

0
votes
1answer
12 views

Error Handling in onInit()

I'm loading information from a SharePoint list in the onInit method. Now I'm wondering how to handle errors. My expectation was that if there's an error the returned promise would fail and some ...
0
votes
1answer
15 views

MSGraph with spfx WebPart does not propt user for permission

I am expermimenting with people in MSGraph. I am attempting the "/me/people" graph call and getting a 403 forbidden. The People.Read permission states it does not need Admin Consent. People ...
0
votes
0answers
23 views

Aditional properties not allowed SPFX webpart error

I'm getting this error when I use gulp serve Blockquote Error: #/localizedResources (A set of localized resources, to be d...) Additional properties not allowed: v3WebPartStrings Error:...
1
vote
0answers
41 views

Adding sections and web parts to the modern pages is not working

@pnp/sp version is 1.2.3/1.2.7 SharePoint version is SPO (online) I am loading the site in the Web object and adding the client side page using the web object. Once the page got created I am adding ...
2
votes
1answer
34 views

SPFX 1.7.1 - Full page apps - How to configure

So i've been away from SPFX for a while since they were still using the older version of React and i've got a question. I can see that they added a developer preview of "Full Page apps". How can you ...
0
votes
0answers
28 views

Getting empty value - please help [on hold]

private _getSiteColumnData(): Promise<any> { let { drpOptions } = this.state; let web = pnp.sp.web; return web.fields.getByTitle("CountryName").get().then(f => { //console....
0
votes
1answer
30 views

Question regarding Typescript version in SPFx

I have few SPFx related queries as mentioned below. What is the current version of typescript in SPFx v1.71? if it is not the latest version then is there any plan to upgrade? It will be great to ...
2
votes
1answer
16 views

Get User's Time Zone using PnPJs

We are trying to retreive current user's profile Time Zone SPS-TimeZone from a SharePoint Framework webpart, but we are faicing an error (see below). Does anyone know about the best/most effecient way ...
0
votes
1answer
21 views

This function always return extra values

While calling the function always get "x" extra added value . Suppose I have received 3 values on 1st call , next 2nd call I received (3 + 3) values , and on 3rd call (6 + 3) values . But I want to ...
1
vote
0answers
20 views

Spfx web part to show task list on modern sharepoint UI

I am looking to leverage team sites for one of my projects. Since modern UI only supports custom lists in web part view, I am looking for some help on how Spfx can be used to show task list web part ...
1
vote
1answer
18 views

SPFx Document Search Result Add-in with ECB / CommandSet option

we are building SPFx based document listview based on search / user personalized view - my bookmarks or recent document; We want to plug in OOTB ECB menu / command set; is there any option to ...
0
votes
0answers
33 views

Error loading SP-webpart-workbench during SPFX webpart tutorial

I have been trying to walk through the tutorial "Build your first SharePoint client-side web part (Hello World part 1)", and I have found it to be quite troublesome. I've worked through many of the ...
2
votes
1answer
44 views

Create document set with REST API in SharePoint Framework

I'm looking for a way to create a document set in my document library from within SPFx web part. I'm using @microsoft/sp-http module to create HTTP requests. Do I need to manually create some ...
5
votes
1answer
67 views

Configure multiple modern SPFx Web Parts on classic pages

We have an issue with Sharepoint Web Parts which have worked perfectly fine in the past, but seem to have broken sometime within the past month without change on our side. One modern web part on the ...
0
votes
1answer
32 views

Calling MS Graph API: An error as soon as declaring the MSGraphClient

I have imported the MSGraphClient in my project using the following statement: import { MSGraphClient } from '@microsoft/sp-client-preview'; I have also added those two import statements, as I will ...
0
votes
0answers
33 views

Connect SPFx webpart and SP list using dynamic data

I know a SPFx webpart can be connected to another SPFx webpart using PropertyPaneDynamicFieldSet and PropertyPaneDynamicField. My question is can a webpart being connected to a SP list? I'll connect ...
2
votes
0answers
21 views

Error in seting up spfx 1.7 with angular 7

Hi I am setting up a SPFX 1.7 project with Angular 7 using the sample which is done with previous version. https://www.youtube.com/watch?v=_OgEqWtouuU https://winsmarts.com/use-spfx-with-angular-cli-...
1
vote
0answers
38 views

SPFx Custon Property Pane not opening

I have created one custom SPFx webpart in which I have placed one link (My Links). By clicking on that link, I am getting links from SharePoint list. When user clicks on the link, it opens Property ...
0
votes
0answers
21 views

Unable to print result in spfx react (got the data)

Getting data from SPFX React (json) - this.state = { testProperty1: "", hideDialog: true, showModal: false, items: [ { Id: "", title: "", ...
0
votes
1answer
32 views

Error while creating list item with multi-user field - pnp js / spfx

In my spfx webpart, I'm creating list item using pnp js. As per pnp-core-js documentation I have written following code, but its failing with error. Private AddListItem() { pnp.sp.web.lists....
1
vote
1answer
38 views

spfx pnp search API: Search by content type and part URL

I have a requirement to makes an SPFX search webpart that can be searched by content type and also partial item url but it has to only return a specific content type from all sites accept root. The ...
1
vote
2answers
39 views

Error when using 'boolean' type property in spfx

I have used office ui fabric 'Checkbox' component in my spfx. For storing value of checkbox I have declared one property with name 'var_Passport' as 'boolean' type. further, I'm assigning value (true/...
1
vote
0answers
24 views

SharePoint Modern Filter option for list view webpart

I have some lists and libraries in SharePoint Online and all are already converted in modern experience (new experience). I want to add these as list view web part in SharePoint Modern page and ...
1
vote
1answer
82 views

How to dynamically bind value (Options) to Dropdown - Office UI Fabric React Components

I'm using Office UI Fabric React dropdown in my spfx webpart. I have added static options in that dropdown as below, but I want to bind options dynamically which i'm getting from REST api. <...
1
vote
1answer
23 views

I want to call one child component from parent component spfx react

I want to call SPFX react child component from parent component . But I am getting error while creating react component . Error: Declaration or statement expected. Cannot find name 'div'. Type '...
1
vote
1answer
36 views

Want to open popup in button click SPFX React

I Want to show modal popup in spfx react webpart. Below is the code I am using: <div> <button onClick={e => this._OpenModal(this)}>Open Modal</button> <div id="myModal" ...
0
votes
1answer
23 views

Sharepoint PnP & SPFX React [duplicate]

While binding the data always getting extra row ... {this.state.items.map(myitems1 => { return ( <div key={myitems1.Id}> <span>{myitems1....
1
vote
1answer
37 views

getting error while retrieving data from sharepoint online spfx react

Trying to get data from SharePoint online using spfx react .. const { siteurl } = this.props; let requestUrl = siteurl.concat( "/_api/web/Lists/GetByTitle('Shoping%20CartItems')/items" ); // Get ...
2
votes
0answers
19 views

SPFX WebPart: Getting HTTPS certificate ERROR in IE11

Getting HTTPS certificate error in IE11, webpart is working fine in chrome, firefox, and Edge but NOT in IE11. The webpart is just displaying some simple list data in dropdown component, and nothing ...
1
vote
0answers
19 views

SPFX and React : Component not rendering correctly because of findDOMNode returns null

I am a new React learner, and I may have a situation with render() and findDOMNode. What I have and what is the wrong behavior : I'm quite new to React so, I may have done lots of mistakes there. I ...
1
vote
0answers
24 views

Create list view webpart using office UI fabrics in SPFX

I want to implement same list view webpart as given in this Office fabric component example article. They have provided code for the same but I don't know how to implement this code. I have created ...
1
vote
1answer
214 views

Failed to execute 'json' on 'Response': body stream is locked

I am following this article and get the following error in the console.log Uncaught (in promise) TypeError: Failed to execute 'json' on 'Response': body stream is locked at e.json (sp-pages-...
0
votes
1answer
49 views

A service principal with the name User Details Custom API for SPFx

I am consuming an Azure API app in a SharePoint Online react app. I am following this article. But when I try to approve the app permissions on the API management page (SharePoint admin centre). I ...
0
votes
1answer
55 views

Provisioning SPFx WebPart assets: adding a page with your webpart embedded to it

As far as I can see it should be doable to create a package which can automatically, once the app is added to your site, to create a page and embed the webpart on it - as described here: https://...
3
votes
1answer
127 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 ...
0
votes
1answer
33 views

Sharepoint (SPFx): APIs working on workbench but on modern pages the /sitePages/ path appears

I'm fairly new to the sharepoint framework so this maybe something quite fundamental that I have misunderstood but here goes: I'm working on a sharepoint framework typescript / react webpart that ...
0
votes
3answers
50 views

Deploy spfx webpart without using cdn

I am currently developing some spfx webpart and i have deployed the webpart and using a SharePoint library as cdn. My question is: Can i deploy the webpart without using a cdn?
1
vote
1answer
39 views

Create SPFx webpart based on existing webpart (Text)

Is there a way to create an SPFx webpart that extends or is otherwise based on an existing built-in webpart? In particular, I want to create a text editor using the default "Text" webpart. I would ...
0
votes
1answer
42 views

How to add checkboxes to propertypane dynamically

I have a dropdown on my property pane which i populated with sharepoint lists. What i want to do now is to add the columns(fields) of the list(selected on the dropdown) as checkbox(on the property ...
1
vote
1answer
49 views

Cannot read property of undefined in spfx

Hear is a SPFx react webpart ".tsx" file code image Have you any solution ?
2
votes
1answer
30 views

Get list of alerts of the current user from the whole site collection

My scenario: i want to create a spfx web part that uses a rest API that will query all the alerts throughout the whole site collection for the current user. I want to know which API to use and ...
0
votes
1answer
31 views

SPFx - Accessing/appending markup that has been entered in via a property pane text field to webpart

I am currently working on an SPFx webpart. Within my property pane I have: PropertyPaneTextField('CreateNewVerticalNav', { label: 'Create New Vertical Nav', multiline: true, ...
0
votes
0answers
39 views

package error when building spfx webpart

I am using the following breadcrum sample. To reproduce the error use command: gulp serve Error I got: ./src/extensions/siteBreadcrumb/SiteBreadcrumbApplicationCustomizer.ts Module parse failed:...
4
votes
1answer
57 views

Should I rewrite all the existing jquery ajax webparts in Typescript or is it better to inject existing jquery in SPFX?

We are moving from SharePoint 2013 to SharePoint Online. We are thinking of migrating existing webparts in 2013, which have jquery - ajax, to SPFX client webparts. Do we have to rewrite all the code ...
4
votes
1answer
138 views

Does Virus affected Node Modules transfer in Contents of SPFx deployment package

When we scaffold an SPFx webpart/Extension we get many Node Modules as part of dependencies. These can be seen in node_modules folder and there are also entries in package-lock.json file. I know ...
1
vote
1answer
40 views

Office UI Dialog not showing correctly on SPFX Web part

On the SharePoint Workspace the UI dialog works fine. The dialog comes out when you click on Forward Case. When I have gulp packaged the solution and adding the app (locally on gulp) then I get this ...
0
votes
0answers
13 views

while New list createion in SPFx issue

I am using SPFx in my project for project createion. While adding project in my List, new 10 dynamic list created using SPFx in backednd it takes 30 second to complete the opertaions. Client ...
2
votes
0answers
30 views

MS Graph API - Problems on SPO Mobile-App

The Background: I am developing Sharepoint Online Webparts on-demand. Sometimes the functionality of these Webparts include the use of Microsoft's "Graph-API" to access Data regarding Office 365 ...
1
vote
0answers
21 views

SPFX Angular Element with UI-Router not displaying data

Iam testing Angular Element with SharePoint Framework (SPFX) Webpart, as Andrew Conell has described in his Blog Every thing is working as asspected, i have added UI-Router in webpart just for ...
0
votes
0answers
37 views

How to load all SPFx webpart on a page after a rest call complete?

I am making a rest request to get user groups and that is required in each SPFx webpart to do some further operation. Scenerio - If 6 SPfx webparts are added on a page and each SPFx webpart is ...