Skip to content

A project template for SharePoint bootstrapped from create react app. This can be used to build an app which can be deployed to SharePoint on-prem site using content editor web part. Tested with SP2013 and SP2016.

Notifications You must be signed in to change notification settings

shashankkaram/sp-onprem-react-starter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This project was bootstrapped with Create React App.

Available Scripts

In the project directory, run:

npm i

Installs the required project dependencies.

npm start

Runs the app in the development mode.
Open http://localhost:3000 to view it in the browser.

The page will reload if you make edits.
You will also see any lint errors in the console.

npm test

Launches the test runner in the interactive watch mode.
See the section about running tests for more information.

npm run build

Builds the app for production to the build folder.
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.
The project was built assuming it is hosted at /SiteAssets/react-starter/.
You can control this with the homepage field in your package.json.

Your app is ready to be deployed! Copy the static folder and the index.html from the build folder into the SharePoint folder specified in the homepage field.
Add a content editor web part on the SharePoint page and point it to the index.html file to view your app.

Additional Notes

  1. The browserslist property in package.json was modified to include ie 11, so that the app works in IE11.
  2. If the app does not load correctly on the SharePoint page, check the dev tools console for any 404 errors related to loading js/css files. Update the references in the index.html file as needed

About

A project template for SharePoint bootstrapped from create react app. This can be used to build an app which can be deployed to SharePoint on-prem site using content editor web part. Tested with SP2013 and SP2016.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published