salesforce-fragment

Generate and validate Salesforce UI fragments against TypeScript interfaces.

803|289|Updated Nov 7, 2025
One-click install
npx skills add https://github.com/forcedotcom/afv-library --skill salesforce-fragment
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: salesforce-fragment
Source: https://github.com/forcedotcom/afv-library/tree/main/skills/salesforce-fragment
Command: npx skills add https://github.com/forcedotcom/afv-library --skill salesforce-fragment

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Solves the problem of designing and maintaining consistent Salesforce UI fragments.

Core Features & Use Cases

  • Generate and edit fragments following Unified Experience Model (UEM) structure
  • Validate fragment definitions against TypeScript interfaces
  • Build fragments for Slack, Mobile, and LEX across Salesforce experiences
  • Troubleshoot deployment issues related to fragments
  • Example: create a shared header fragment used across multiple apps to ensure consistency

Quick Start

Describe the fragment you want to build and I will generate a UEM-compliant fragment tree ready for deployment.

Frequently Asked Questions about salesforce-fragment

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

FAQPage Schema
How do I generate reusable Salesforce UI fragments for multiple experiences?

To generate reusable Salesforce UI fragments, describe the desired component and the system produces a UEM-compliant fragment tree. This ensures consistent, deployable UI structures across Slack, Mobile, and LEX platforms.

What is the Unified Experience Model structure for Salesforce fragments?

The Unified Experience Model (UEM) structure is a standardized framework for composing Salesforce UI fragments. It enforces TypeScript-based interface validation to ensure fragments remain safe and deployable across different Salesforce experiences.

Can I build a single Slack UI fragment and reuse it in LEX and Mobile?

Yes, you can build a single fragment and reuse it across Slack, LEX, and Mobile. The system applies a TypeScript-based fragment model to compose shared UI components, ensuring visual and structural consistency across apps.

How do I validate fragment definitions against TypeScript interfaces in Salesforce?

Validating fragment definitions against TypeScript interfaces is handled automatically during generation. The system enforces a TypeScript-based fragment model and UEM structure validation to catch definition errors before deployment.

Why are my Salesforce UI fragments failing deployment validation?

Salesforce UI fragments fail deployment validation when they do not conform to the required UEM structure or TypeScript interfaces. You can troubleshoot these deployment issues by regenerating the fragment to ensure it meets validation rules.

Does generating Salesforce fragments require manual TypeScript coding?

Generating Salesforce fragments does not require manual TypeScript coding. You simply describe the fragment you want to build, and the system outputs a UEM-compliant fragment tree that already enforces the necessary TypeScript interfaces.