Stack Exchange Network

Stack Exchange network consists of 174 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 [react]

React is a JavaScript library for building user interfaces. It uses a declarative paradigm and aims to be both efficient and flexible.

1
vote
0answers
7 views

@types/react and @types/prop-types errors when building with gulp build or gulp serve

For my team's project, some of us are hitting a type issue when building. We're using version 1.7.0 of all the @microsoft/sp- packages. tslint version: 5.9.1 typescript version: 2.4.2 Build tools ...
0
votes
0answers
18 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://...
0
votes
3answers
24 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?
0
votes
0answers
13 views

Sharepoint SPFx active toggle in list view

I'm new with SharePoint Framework and I want to achieve something like this: Github - React Field Toggle This solution is for SPFx v1.3 and in my environment (SharePoint Online) it's not working even ...
1
vote
1answer
32 views

Can I use SPFx 1.7 with Sharepoint 2016 Feature Pack 2 updated to the latest January 2019 patch?

We have an on-prem Sharepoint 2016 server which has been kept up to date with the latest security and feature updates and patches. We want to build a client application using SPFx Web parts, ...
0
votes
1answer
32 views

Spfx breadcrumb not working on modern team site

I am using the following breadcrum sample. I have deployed the latter to app catalog and it works fine in a developer site with modern pages/library but it doesn't work in a modern team site.
2
votes
1answer
22 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
28 views

Upload attachment to List Item using React & Axios (REST API)

Well the title pretty much sums it up. I've got a custom form outside of sharepoint that creates/updates/views items from a sharepoint list using Rest API (with accessToken). Now i need to be able ...
0
votes
0answers
33 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:...
1
vote
1answer
33 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
1answer
41 views

Multiple attachment upload causing 409 conflict error. (SPFX, PNP)

I have noticed a bug when using the PnP library for SPFX to upload multiple attachments. Using: sp-pnp-js@3.0.10 targeting: SharePoint Online Expected Behavior Question When uploaded multiple ...
1
vote
1answer
27 views

How can I create webpack package of SharePoint online for react App?

I can create package of react app for SharePoint online by using "gulp serve" and "gulp package-solution" commands. However, I want to create package by using Webpack. How can I achieve this?
2
votes
0answers
20 views

I need to get all properties of taxonomy termstrore. which I already get are “Label”,“WSSId”,“TermGuid” but I need to get Other labels as well

Is there any solution to get other properties for taxonomy termstore. As I remember, I usually used "include" to get all properties which I mentioned in JSOM. But now I need to work by using ...
1
vote
0answers
41 views

Office UI Fabric React People Picker Remove 'X'

Is there a way I can have certain personas unremovable from people picker? I was thinking how I can remove the X button: On the screenshot, I need to disable removal of test user2 and Test 115 while ...
0
votes
0answers
27 views

SPFX: Custom action to move bulk document from one library to another and adding metadata to these files

My scenario: I need to be able to bulk move files from one library to another and also bulk add metadata to those newly move files. I thinking of creating an spfx/react application or any method is ...
3
votes
0answers
21 views

Create-react-app version 2 not compatible with SharePoint?

I'm trying to make a web part with React (not SPFx, just a regular mini React app) for use in SharePoint. I have done so successfully with version 1.x of react-scripts, but now 2.x is out, with ...
0
votes
1answer
29 views

Possible to track session of user in sharepoint?

i just got a requirement to modify some code in my SPFX app to detect a user sessions. the requirements is that i have to lock that specific list which is tracked by a separate tracking list (schema: ...
0
votes
1answer
62 views

React Native (Sharepoint-application)

I have started learning to code in react native. Have an idea of trying to create an application that (creates / updates / deletes) data from SharePoint lists. My question is: How do I create a ...
0
votes
2answers
94 views

Getting error 'response.map is not a function' trying to map a list items with managed metadata fields in spfx react solution

I am trying to get items from a links list with managed metadata. I am getting an error 'response.map is not a function'. I have used the sample from this answer to get the data using ...
-1
votes
0answers
33 views

How to create SharePoint typescript react module

I'm trying to make my own module which allows to create component templates and transpile everything to a single js file to be able to use it as external templates in SPFx webparts. Currently i'm able ...
0
votes
1answer
119 views

react, spfx and taxonomy

I am using react to get the term by id, but the problems is that I am not able to get any child term under the term.For example: -IT --software --hardware IT is term not termSet. taxonomy....
2
votes
1answer
131 views

Add Dynamic Property Panes to SPFX

I know this has been asked 1000 times, but i've tried everything in the first 2 pages of google so i've decided to come to you guys for help. I'm trying to create some dynamically added property ...
0
votes
1answer
932 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 ...
1
vote
2answers
258 views

Trying to use SPFX + React. Error “yo : The term 'yo' is not recognized as the name of a cmdlet”

I want to build my first SPFX React web part, so i am following this article:- https://docs.microsoft.com/en-us/sharepoint/dev/spfx/web-parts/get-started/use-fabric-react-components first step i ...
0
votes
0answers
85 views

SharePoint Framework Web Part on a Classic page

I created a React - web part for SharePoint using react-slick carousel and react-player. The web part works great and is responsive on modern pages. I created a custom classic page layout using ...
0
votes
1answer
60 views

SPFX Textarea Render Issue in IE11

I have the above Textarea displaying some dynamic address, it displays and keeps my CSS styling as wanted in Chrome (Version 67.0.3396.99 (Official Build) (64-bit) ) with no border or other issues but ...
1
vote
1answer
101 views

SP 2013 - Calling list data from create-react-app on separate domain

We want to read and update SP2013 list data from our purely client-side javascript create-react-app project. Our production build files (html and js) can be hosted in the same domain on SharePoint (...
3
votes
2answers
83 views

How to combine two SPFx web parts?

We have two separate SPFx web parts (call them A and B), and you can add A and/or B to same SharePoint Online site. Now there is a need to create web part C that combines both A and B into single web ...
0
votes
2answers
32 views

Add a link on top of html elements (React)

I have a "meeting radar" on my SharePoint witch is build using react I think and I wish to upgrade. Unfortunatly, even though I am starting to have a correct js level, I dont understand this code and ...
1
vote
1answer
657 views

SPFx - Get User ID from User Login Name

As the title suggests, does anyone have a working method for getting a users ID from a users Login Name (not the one signed in)? Login name like: i:0#.f|membership|firstname.lastname@contoso....
1
vote
1answer
97 views

Reuse Child Component Method to Parent Component Fabric React - SPFx

I am using Fabric React with SPFx. I want to use one component public method to another component. How can be possible to reuse method? My Parent Component: export class PanelSmallRightExample2 ...
1
vote
1answer
98 views

Office UI Fabric Ract Command Giving an error UNMET PEER DEPENDENCY

Issue while adding command "npm --save install office-ui-fabric-react" NPM Version: @microsoft/generator-sharepoint@1.0.2 gulp@3.9.1 yo@2.0.2 How to solve this issue? It gives warning:office-ui-...
0
votes
0answers
212 views

SPFx and React: how to filter on cascading dropdownlists?

I am using the example from Github, but I am not sure how to filter the second dropdown list based on the selected value in the first list: <MyAsyncDropdown label ="Select a site" ...
1
vote
1answer
163 views

SharePoint 2016 SPFx React TypeScript Issue

I am getting an error of TypeScript 2.2.2 in SharePoint 2016. I can install SPFx web part with No JavaScript Framework approach. And it's working fine but when I choose "React" in "yo @microsoft/...
1
vote
1answer
207 views

Cascading dropdown list in SPFx web part

Can someone help me with this issue as I would like to create cascading dropdown lists inside the web part itself and not in the property pane. I have found this code in [github react-...
0
votes
0answers
303 views

Advanced SPFx Search box web part

I have found a spfx search box in github, but I was wondering if there is one that has advanced functionality, like searching for specific sites, libraries, by content type? Is it possible to use ...
1
vote
1answer
144 views

SPFx get all sites were user has permissions

is there a way to get all site collections and subsites where the current user has access to? I would like to build a web part in SPFx and in React. Any suggestions are welcome. Thank you.
0
votes
1answer
40 views

Implement taxonomy field on a custom react app

I am developing a custom react app. I need taxonomy and people picker controls on the app. Please let me know if this is possible and if yes, how.
0
votes
1answer
32 views

Saving data from a multi-page react app

I am trying to emulate a sharepoint new form in a custom react app of multiple pages. My problem is how will I store the data that user enters across multiple pages and save it in the sharepoint list. ...
0
votes
0answers
66 views

Custom web API for communication with SharePoint Online

I am new to web APIs and need to create a custom web API for communication with a SharePoint Online list. There is no Azure involved. I am also required to create a React app which will in turn, ...
0
votes
1answer
84 views

Return only one item from the list

I'm trying to display checkbox of some of the popular links but I face this problem. I can't return more than one item (first one). Any Ideas how to display all of them (5). private getItems(){ ...
0
votes
0answers
364 views

Property 'serviceScope' does not exist on type 'IWebPartContext'

I'm trying to Recreate this sample/demo I face a problem when I try and run the same or create it from scratch myself. I get the following 2 errors: error TS2339: Property 'serviceScope' does not ...
1
vote
0answers
456 views

Using SP-PNP-JS to get data from custom content type fields with React

I'm currently making News Listing Web Part, where News are made as custom content type. I managed to get the basic fields like id, title, but others are really bothering me. The API fetches all the ...
0
votes
2answers
672 views

Spfx, WebParts and PnP : How to get the current user id?

Good morning every SharePoint fellow ! I know this question has surely already been posted, but i could'n't found a clear answer. Context I am programming a custom WebPart for Sharepoint online with ...
0
votes
1answer
240 views

ReactJS web part list items with delete button, delete executes when rendering

I am using SPFX to render items from a list in a table that includes a delete button for each row item. Here is a condensed version of the parent component: export interface IHelloWorldState { ...
0
votes
2answers
633 views

Setting default value office ui fabric react people picker

I'm currently using the CompactPeoplePicker component however I'm looking to extend it using the selectedItems property to set the people picker from a rest call. <CompactPeoplePicker ...
0
votes
1answer
567 views

React State in Property Pane?

While using SPFx with React how do I use state in the property pane to change and manipulate values instead of default properties? Can I add state to the BaseClientSideWebPart? Or is there another way ...
2
votes
1answer
134 views

How to change state in webpart.tsx from wepart.ts property pane - SPFx

I am trying to add a button to my property pane that will pop up a modal where the user will be able to enter in an image to be displayed on my banner webpart which is just an image carousel. I ...
0
votes
0answers
86 views

Getting error sp-webpart-workbench-assembly_en-us_ Uncaught TypeError: Cannot read property 'searchablePlainTexts' of undefined

I am trying to imitate the React todolist webpart using semantic-ui-react component instead of office-ui-fabric. i followed this sample-->(https://github.com/SharePoint/sp-dev-fx-webparts/tree/master/...
0
votes
0answers
42 views

Debugging React components in spfx client side webparts

How can I step through my .tsx code file line by line? Either using Google Chromes developer tools or Visual studio code the debugger steps into internal Typescript/JavaScript libraries? It becomes ...