Show answerHide answer
Correct answer: C App Builder styling property
Explanation
ExplanationTo allow administrators to modify a Lightning Web Component's (LWC) appearance directly within the Lightning App Builder, developers must expose component properties. This declarative approach empowers non-technical users to adapt the component’s style or behavior based on the specific page context—such as Home, Record, or App pages—without writing code.
✅ Correct Option: C. App Builder styling property
An App Builder styling property (defined via @api properties in JavaScript and
❌ Incorrect Option: A. Styling hooks
Styling hooks are CSS custom properties used by developers to modify the internal styles of Salesforce base components or custom blueprints. While they are powerful for theme-level changes, they are controlled within the CSS files of the code bundle. Administrators cannot interact with styling hooks through a point-and-click interface like the Lightning App Builder to change individual component instances.
❌ Incorrect Option: B. CSS loaded as a static resource
Loading CSS as a static resource is a method for applying global or shared styles across components using the loadStyle service. This is a technical implementation detail handled by developers. Administrators do not have the ability to swap or configure these static resources on the fly while designing a page in the App Builder to change specific component aesthetics.
❌ Incorrect Option: D. SLDS utility classes
SLDS utility classes are predefined CSS classes (like slds-p-around_small) used within the component's markup to handle spacing, alignment, and visibility. These are "hard-coded" into the HTML template by the developer. Since they are part of the component’s source code, administrators cannot change or swap these classes through the App Builder UI.
📝 Summary
The App Builder styling property is the correct recommendation because it enables declarative customization. By exposing properties in the component's metadata, developers allow administrators to define unique "look and feel" settings for different page types. This ensures the component remains flexible and reusable across the entire Salesforce org.
Reference:
Salesforce Developers: Configure a Component for Lightning App Builder