Yeoman generator for SharePoint client-side applications
Yeoman generator for SharePoint - lets you quickly set up a project with sensible defaults for pulling and pushing files between SharePoint asset library and local projects sources.
Generated project allows immediately start developing SharePoint client-side solutions in Visual Studio Code or any other editor with instant publishing changes to SharePoint web site and downloading specific assets from SP Document library folder to local project assets which can be enforced with Git Diff algorithm for tracking changes.
- Live reload functionality is integrated
- Dynamic configuration helpers
- SharePoint Online
- SharePoint 2013
- SharePoint 2016
To use Yeoman, one need to has Node.js and NPM installed on the computer. Basic installation process description can be found in this blog post.
Alter Node.js and NPM are staffed, install Gulp
, Bower
, Yeoman
and generator-sppp
globally in your Node.js environment.
npm install -g gulp bower yo generator-sppp
Make a new directory or clone a blank Git project of your own and navigate to the created folder.
Inside project directory execulte:
yo sppp [YourProjectName]
Then follow the the Yoman wizard instructions:
Now you can run gulp sppull task:
gulp sppull-all
It will deliver all files from assets folder from SharePoint to local directory.
Run gulp watch task before starting editing files:
gulp watch-assets
On files change they are uploaded and published to SharePoint with use of gulp-spsave.
For publishing all .src project files, publish
task can be used:
gulp publish
gulp touch-conf
Checks basic minimal configs and prompts on configuration missing.
gulp watch-live
Chech sp-live-reload project page more information.
- sppull library is used for downloading files from SharePoint
- gulp-spsave library is used for saving files to SharePoint
- sp-request and node-sp-auth are in charge for low level communication with SharePoint
- sp-live-reload library is used for instantaneous page reload
Communication layer settings are stored in ./config/_private.conf.json
, parameters settings description can be found here.