Sharepoint 2013 React App

Copper Contributor

I am in an odd scenario where I have a Sharepont 2013 site collection.  Sadly we do not have the app model turned on so I cannot use visual studio.  I am using VS code to use the create-react-app scaffold and I cannot seem to do any fetch calls from local host 3000 (as its considered cross domain rest calls).  This means when i run the dev server on local host I cant see how the data flows in/out.  So I guess I have 2 questions.

 

  1. Is it truly possible to use local host to connect to sp 2013 with no app model (I have no hive access so no central admin)?  Especially, when I keep getting CORS restrictions and 401 errors when trying to authenticate with a fetch rest call.
  2. If not would I literally have to run npm build and upload to sharepoint to test everything?

 

5 Replies

Are you talking about the SharePoint Framework SPFX yomen app generator?

 

If so that is not supported in SharePoint 2013.

 

Cheers

Alex  

 

Yes sadly I am aware that I have no access to SPFX.  It makes me cry a little on the inside every time I think about it.  That being said I found a library called sp-rest-proxy.  I hope that it can do what I am asking or I really just don't know if its possible in my scenario.

That sounds like a really bad time man, If its simple you could just use a script editor webpart.

 

otherwise development choices are very limited without using visual studio/sharepoint app model 

 

Yeah I wish it was simple its a single page (multi view) react app I am building.  It has lots of components and is starting to come together.  Then of course I start testing Fetch requests and 401/cors policy issues abound.  I really hate our implementation of SP2013.  It literally has half of the feature set turned off.  That and we are still using 2010 workflows.  meh.

@JustJim sounds like your environment is the same as ours...  Did you ever get this working?  I've built several Fluent UI React apps for our crippled SP2013 implementation, and I won't lie, testing and troubleshooting has been Hell.