Skip to content

New command: add client-side web part to modern page #366

@waldekmastykarz

Description

@waldekmastykarz

Add client-side web part to modern page

  • command: spo page clientsidewebpart add -n|--pageName <pageName> -u|--webUrl <webUrl> --standardWebPart [standardWebPart] --webPartId [webPartId] --webPartProperties [webPartProperties] --section [section] --column [column] --order [order]
  • pageName: name of the page to add the web part to
  • webURL: URL of the site where the page to edit is located
  • standardWebPart: set to add one of the standard SharePoint web parts. Available values: ThirdParty|ContentRollup|BingMap|ContentEmbed|DocumentEmbed|Image|ImageGallery|LinkPreview|NewsFeed|NewsReel|PowerBIReportEmbed|QuickChart|SiteActivity|VideoEmbed|YammerEmbed|Events|GroupCalendar|Hero|List|PageTitle|People|QuickLinks|CustomMessageRegion|Divider|MicrosoftForms|Spacer
  • webPartId: set to add a custom web part
  • webPartProperties: JSON string with web part properties to set on the web part
  • section: number of section to which the text should be added (1 or higher)
  • column: number of column in which the text should be added (1 or higher)
  • order: order of the section
  • specify standardWebPart or webPartId but not both

For more information see the Add-PnPClientSideWebPart cmdlet.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions