
Security News
Socket Integrates With Bun 1.3’s Security Scanner API
Socket now integrates with Bun 1.3’s Security Scanner API to block risky packages at install time and enforce your organization’s policies in local dev and CI.
@agility/web-studio-sdk
Advanced tools
Standard Development Kit used to enable Web Studio features in Agility CMS
This is the official JavaScript/TypeScript SDK for Agility CMS's Web Studio.
Don't have an Agility CMS instance? Sign up for Free Trial today!
You'll need to have an Agility CMS instance to use this SDK. If you don't have one, you can sign up for a Free Trial today!
Once you have an Agility CMS Instance you will need to install the sdk from npm and add a script tag in your website.
<script src="https://unpkg.com/@agility/web-studio-sdk@latest/dist/index.js"></script>
You can stop there if you'd like. But to get the most of the SDK, you'll need to decorate your components, fields, and pages with the data-agility-* attributes. This will allow the SDK to interact with your website/app, and enable real-time editing. You'll also need to add your guid as a data-agility-guid attribute to the root element of your website/app.
<!DOCTYPE html>
<html lang="en" data-agility-guid="YOUR_GUID">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Document</title>
</head>
<body>
<div data-agility-page="YOUR_PAGE_ID">
<header data-agility-component="YOUR_CONTENT_ID">
<h1 data-agility-field="title">{{fields.title}}</h1>
<p data-agility-field="content">{{field.content}}</p>
</header>
</div>
</body>
</html>
npm
npm install @agility/web-studio-sdk
yarn
yarn add @agility/web-studio-sdk
You will need to have an Agility CMS instance and a website that you can also run locally. In the root of your site, add the following script tag
<script src="http://127.0.0.1:8080/index.js"></script>
Clone this repository
Run npm install
Run npm run dev
On the Sitemaps page in Agility CMS, add a preview deployment that points at where your website is running locally, usually http://localhost:3000
.
Go to the Pages module in Agility CMS and click on the "Preview" button to see the Web Studio in action.
Also here is a handy Regex that's useful for debugging frame events in the chrome dev tools console:
/^Web Studio (SDK|CMS)/
For docs & help around Agility CMS, please see Agility CMS Documentation
If you would like to contribute to this SDK, you can fork the repository and submit a pull request. We'd love to include your updates.
FAQs
Standard Development Kit used to enable Web Studio features in Agility CMS
The npm package @agility/web-studio-sdk receives a total of 106 weekly downloads. As such, @agility/web-studio-sdk popularity was classified as not popular.
We found that @agility/web-studio-sdk demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 6 open source maintainers collaborating on the project.
Did you know?
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.
Security News
Socket now integrates with Bun 1.3’s Security Scanner API to block risky packages at install time and enforce your organization’s policies in local dev and CI.
Security News
Python 3.14 adds template strings, deferred annotations, and subinterpreters, plus free-threaded mode, an experimental JIT, and Sigstore verification.
Security News
Former RubyGems maintainers have launched The Gem Cooperative, a new community-run project aimed at rebuilding open governance in the Ruby ecosystem.