Book Image

SharePoint Development with the SharePoint Framework

By : Jussi Roine, Olli Jääskeläinen
Book Image

SharePoint Development with the SharePoint Framework

By: Jussi Roine, Olli Jääskeläinen

Overview of this book

SharePoint is one of Microsoft's best known web platforms. A loyal audience of developers, IT Pros and power users use it to build line of business solutions. The SharePoint Framework (SPFx) is a great new option for developing SharePoint solutions. Many developers are creating full-trust based solutions or add-in solutions, while also figuring out where and how SPFx fits in the big picture. This book shows you how design, build, deploy and manage SPFx based solutions for SharePoint Online and SharePoint 2016. The book starts by getting you familiar with the basic capabilities of SPFx. After that, we will walk through the tool-chain on how to best create production-ready solutions that can be easily deployed manually or fully automated throughout your target Office 365 tenants. We describe how to configure and use Visual Studio Code, the de facto development environment for SPFx-based solutions. Next, we provide guidance and a solid approach to packaging and deploying your code. We also present a straightforward approach to troubleshooting and debugging your code an environment where business applications run on the client side instead of the server side.
Table of Contents (14 chapters)

Deploying assets to a SharePoint Online CDN

Now we are ready to deploy our bundled assets to SharePoint Online-based CDN. Upload all the .js -files from your /temp/deploy folder to the Site Assets/cdn folder in your SharePoint Online Site:

Note that you do not need to upload any assets that will not be used by your solution.

We still have to update our old previously deployed SharePoint Framework package. In order to do this, navigate back to your App Catalog site and re-upload the new .sppkg file to replace the old version (which did not use CDN).

Upon completing the upload, you'll get the dialog for deploying the solution just like before. Note that it now takes into consideration the CDN path and shows you the full URL where content will be served:

If you still have the web part on the page, navigate to your SharePoint Online site where the previous deployment took place. When you reload the page, content should be served correctly, without gulp serve running in your localhost...