Building Blocks

Create and refine AEM Edge Delivery blocks with JS decoration and CSS styling.

3|Updated Apr 17, 2025
One-click install
npx skills add https://github.com/arbory-digital-inc/sas-demo --skill building-blocks-arbory-digital-inc
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Building Blocks
Source: https://github.com/arbory-digital-inc/sas-demo/tree/main/.claude/skills/building-blocks
Command: npx skills add https://github.com/arbory-digital-inc/sas-demo --skill building-blocks-arbory-digital-inc

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill guides developers in creating new AEM Edge Delivery blocks or updating existing ones, ensuring decoration logic, CSS styling, and content model alignment are implemented consistently.

Core Features & Use Cases

  • Create new block structures under blocks/{block-name}/ with corresponding {block-name}.js and {block-name}.css
  • Implement JavaScript decoration to transform authored content into interactive experiences
  • Apply scoped CSS styling that adheres to design tokens and responsive guidelines
  • Validate content models and ensure code quality through testing

Quick Start

Create a new block by running the Building Blocks skill to scaffold the block directory, add the JavaScript and CSS skeleton, implement decoration, and apply styling per guidelines.

Frequently Asked Questions about Building Blocks

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a new AEM Edge Delivery block from scratch?

To create an AEM Edge Delivery block, you need to scaffold a directory under blocks/{block-name}/ and add corresponding {block-name}.js and {block-name}.css files. This establishes the standardized file structure required for implementing block decoration and styling.

How does JavaScript decoration work for AEM Edge Delivery blocks?

JavaScript decoration transforms authored content into interactive experiences within AEM Edge blocks. You implement this logic in the block's .js file to manipulate the DOM structure based on the defined content models and project guidelines.

What is the standard file structure for AEM Edge Delivery blocks?

The standard file structure for AEM Edge Delivery blocks requires a dedicated directory named blocks/{block-name}/ containing both a {block-name}.js file for decoration logic and a {block-name}.css file for styling.

Can I use frontmatter-driven metadata in AEM Edge block creation?

Yes, frontmatter-driven metadata is enforced during AEM Edge block creation to ensure proper content model alignment. This approach standardizes how configuration and content attributes are applied across different blocks.

What's the best way to apply CSS styling to AEM Edge blocks?

The best way to apply CSS styling to AEM Edge blocks is by using scoped CSS within the {block-name}.css file. This ensures styles adhere to project design tokens and responsive guidelines without affecting other page elements.

Why does my AEM Edge block need code quality and testing validation?

Code quality and testing validation are required for AEM Edge blocks to ensure decoration logic and content models function correctly. Adhering to project guidelines prevents runtime errors and maintains structural consistency across the delivery pipeline.