Socket
Book a DemoInstallSign in
Socket

@pantheon-systems/pcc-browser-sdk

Package Overview
Dependencies
Maintainers
5
Versions
65
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pantheon-systems/pcc-browser-sdk

Pantheon Content Publisher Browser SDK

latest
npmnpm
Version
5.0.1
Version published
Maintainers
5
Created
Source

Browser

Pantheon Content Publisher SDK for Browsers

A simple and easy to use browser client for the Pantheon Content Publisher API


Requirements

  • A published Pantheon Content Publisher article
  • A Pantheon Content Publisher Token. Obtain one from the PCC CLI.

Usage

  • Add the script tags that load the SDK to your HTML file:
<-- Add this to the <head> of your HTML file or right before the closing </body> tag -->
<script
  src="https://unpkg.com/@pantheon-systems/pcc-browser-sdk@latest/dist/index.js"
  data-site-id="<your PCC Site ID>"
  data-token="<your PCC Token>"
></script>
  • Add the pcc-article custom element to your HTML file. Place it where you want the article to be rendered.
<pcc-article id="<id of your article>">
  <!-- Add a fallback message here for when the article is loading... -->
  Loading...
</pcc-article>

That's it! You should now see yur article rendered in your browser.

Options

The pcc-article custom element accepts the following attributes:

AttributeTypeRequiredDescription
idStringYesThe ID of the article you want to render
slugStringYes if id is not providedThe slug of the article you want to render
disable-stylesBooleanNoDisable rendering default styles for the article

FAQs

Package last updated on 12 Sep 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts