Deployment guide
TL;DR: You build your project, package a .sppkg, and upload it to the app catalog. Then you approve permissions and add the web part to a page.
This guide shows the path from code to a live web part. For exact outputs, see ../reference/architecture.md.
Pipeline overview
sh
rspfx build # -> dist/ + release/manifests + release/assets
rspfx package # -> sharepoint/solution/<name>.sppkg
rspfx deploy # -> upload .sppkg to app catalog via REST| Command | Output | Use |
|---|---|---|
rspfx build | dist/<bundle>.js and release manifests | CI and analysis |
rspfx package | sharepoint/solution/<name>.sppkg | ship |
rspfx package --no-build | same .sppkg from existing release/ | incremental |
rspfx deploy | packages and posts to catalog | automated upload |
npm run build and npm run package proxy to the same commands.
CDN notes
includeClientSideAssets | cdnBasePath | Result |
|---|---|---|
true | "" | Bundles embedded in .sppkg under ClientSideAssets/. No CDN needed. |
false | "" | No ClientSideAssets. Load fails unless you host files. Avoid this. |
false or true | "https://cdn.contoso.com/<name>/" | Manifests point to that URL. Upload release/assets/* to the CDN. |
cdnBasePath must end with /. Use the first row unless you need an external CDN.
Troubleshoot
| Symptom | Fix |
|---|---|
| Bundle 404 in workbench or page | bundle name does not match entryModuleId |
External X could not be resolved | remove the externals entry or install X |
Can't resolve XxxWebPartStrings | check localizedResources pattern includes {locale} |
paths.zippedPackage missing | check package-solution.json has solution.id, solution.name, paths.zippedPackage |
| Sync to Teams missing | check teams/ existed at package time and includeClientSideAssets is true |
For internals, see ../reference/architecture.md.