SharePoint Developer Documentation

repository·main·Indexed 23 days ago

https://github.com/sharepoint/sp-dev-docs

Official resources, guides, and API references for SharePoint development. Covers the SharePoint Framework (SPFx), SharePoint Embedded, list formatting, site templates, and site scripts. Includes detailed documentation on Application Lifecycle Management (ALM) APIs for managing SPFx solutions and add-ins via SharePoint REST API, PnP CSOM, PnP PowerShell, and CLI for Microsoft 365.

Tokens
249K
Snippets
354
Records
931
Agent score
79%

What's inside SharePoint Developer Documentation

  1. Overview of customization options for modern lists and libraries

    main

    The "modern" experience for SharePoint lists and libraries is designed for speed and responsiveness, but it supports a different set of customization capabilities compared to the "classic" experience.

    Supported Customizations

    • Subset of user custom actions: You can add specific custom actions to the UI.
    • Custom branding: Visual styling of the interface.
    • PowerApps and Flow integration: Deep integration with Microsoft Power Platform.
    • SharePoint Framework (SPFx) Extensions: You can use SPFx to control field rendering and create user custom actions that execute custom code.

    Unsupported Customizations

    If your current solution relies on the following, you must migrate to SPFx or other modern alternatives:

    • JSLink: Both field and view customizations based on JSLink are not supported.
    • Custom CSS: Using the AlternateCSSUrl web property is not supported.
    • Embedded JavaScript: Custom JavaScript injected via user custom actions is not supported.
    • Master Pages: Custom master pages are not supported.
    • InfoPath: Customization via InfoPath is not supported.
    • MDS: Minimal Download Strategy is not supported.
    • Server Publishing: SharePoint server publishing features are not supported.
  2. Overview of SharePoint Embedded

    main
    SharePoint Embedded is a cloud-based, API-only file and document management platform built on Microsoft 365. It allows developers to embed Office collaboration, Microsoft Purview compliance, and Copilot into their own applications. A key architectural feature is that documents remain stored within each customer's specific Microsoft 365 tenant, rather than in a centralized developer-managed storage.
  3. What is SharePoint Embedded?

    main

    Microsoft SharePoint Embedded is a cloud-based, API-only file and document management system built on Microsoft 365. It is designed for developers building line-of-business applications and Independent Software Vendors (ISVs) building multitenant applications.

    Key Characteristics:

    • API-only: There is no standalone end-user interface or no-code option. Access is provided exclusively through Microsoft Graph APIs.
    • Tenant-resident: Content physically resides within the customer's Microsoft 365 tenant in a dedicated storage partition, but is only reachable via your application.
    • Advanced Capabilities: Integrates Microsoft 365 features like Office collaboration (Word, Excel, PowerPoint), Microsoft Purview security/compliance, and Copilot.
    • Billing: Does not count against standard Microsoft 365 storage entitlements; it is billed via an Azure subscription on a pay-as-you-go, metered model based on storage and API usage.
  4. Benefits of migrating to SharePoint Framework

    main

    Migrating from legacy Feature Framework customizations to SPFx provides several advantages:

    • Modern Site Support: SPFx is the only supported way to customize "modern" sites. Modern sites have the no-script flag enabled, which prevents legacy user custom actions and embedded JavaScript from executing.
    • Microsoft 365 Integration: Unlike the legacy model which relied heavily on JSOM or low-level REST APIs, SPFx makes it straightforward to consume both the SharePoint REST API and Microsoft Graph, allowing for deeper integration with the Microsoft 365 ecosystem.
    • Script Isolation: SPFx packages scripts as modules. This allows different extensions on the same page to use different versions of the same library (e.g., jQuery) without version collisions.
  5. Search how-tos for SharePoint

    main

    Advanced search configuration and customization guides:

    • Crawling External Content: Use Business Data Connectivity (BDC) service metadata to crawl associated external content types and configure item-level security.
    • BLOB Crawling: Modify BDC model files for BCS indexing connectors to enable crawling of Binary Large Objects (BLOBs) from SQL Server.
    • Content Enrichment: Implement a web service callout to modify managed properties of crawled items before indexing.
    • Security Trimming: Implement a custom security trimmer to control search result visibility.
  6. Explore SharePoint extensibility topics

    main

    The SharePoint developer ecosystem covers several key areas of customization:

    • SharePoint Framework (SPFx): The modern approach to building extensions and web parts.
    • SharePoint Embedded: For building applications within the SharePoint experience.
    • List formatting: Declarative customization using JSON for columns and views.
    • Site templates & site scripts: Automating site provisioning and configuration.
    • SharePoint add-ins: Note: SharePoint add-ins will reach end-of-life in April 2026 for SharePoint Online / Microsoft 365.
  7. Explore further SharePoint Copilot App resources

    main

    After completing the initial build, you can deepen your understanding using these resources:

  8. Retirement of SPFx domain isolated web parts

    main

    Microsoft is retiring the domain isolated web parts feature in SharePoint Framework (SPFx). Domain isolated web parts, which run in a separate domain from the host page for security, are being phased out due to performance implications.

    Retirement Timeline

    • April 2, 2025: Domain isolated web parts will be disabled for newly created tenants.
    • April 2, 2026: Domain isolated web parts will be disabled for existing tenants. After this date, web parts will render an error message and stop functioning.

    There is no option to extend this retirement period. Microsoft is investigating alternative strategies, but the current recommendation is to migrate to regular web parts.

  9. Consume the Microsoft Graph in the SharePoint Framework

    main

    You can consume Microsoft Graph REST APIs or any other REST API registered in Azure AD from within a SharePoint Framework (SPFx) client-side web part or extension.

    Starting with SPFx version 1.4.1, you should use the native MSGraphClientV3 for Microsoft Graph operations. Using the Microsoft Authentication Library for JavaScript (MSAL) directly to consume Microsoft Graph is not supported in SPFx v1.4.1 and beyond.

    For general Azure AD-secured REST APIs, you can use the AadHttpClient type.

  10. BCS (Business Connectivity Services) how-tos for SharePoint

    main

    Guides for connecting SharePoint to external data sources via BCS:

    • External Content Types (ECT): Create ECTs for SQL Server or discover OData sources using Visual Studio to create reusable ECTs.
    • OData Integration: Create OData data services to send notifications to SharePoint for triggering external list events, and create external lists programmatically using OData sources.
    • Add-in Scoped ECTs: Create external content types specifically for use within SharePoint Add-ins.
    • Data Access: Access external data using REST URLs or the SharePoint client object model (CSOM) via browser-based scripting.
  11. SharePoint Framework (SPFx) Toolchain Requirements

    main

    To build SharePoint Framework solutions, your development environment must include the following core tools:

    • Node.js: The runtime for design-time tools used to build and package projects. It is installed globally. If you need to manage multiple versions of Node.js, use a version manager.
    • npm: The package manager used to install the SPFx toolchain and project dependencies. It is a Node.js package; each Node.js version installed will have its own version of npm.
    • Heft: A config-driven toolchain used to invoke tools like TypeScript, ESLint, Jest, Webpack, and API Extractor. It is typically invoked via package.json scripts such as npm run build or npm run test.
    • Yeoman and SharePoint Framework Yeoman generator: Used to scaffold new SPFx projects or add components (like web parts) to existing ones.
      • Note: The SPFx Yeoman generator is tied to specific versions of the framework. To avoid version mismatches when adding components to older projects, it is recommended to install the generator locally within the project rather than globally.
    • TypeScript: Used for type-safe development. SPFx projects include their own version of TypeScript in the project dependencies, so you do not need to install it separately on your machine.