Courseiva

SALESFORCE-PD1 · topic practice

User Interface practice questions

This domain covers building user interfaces on the Salesforce Platform with Lightning Web Components, Aura components, and Visualforce. Questions test lifecycle hooks, component composition and slots, Lightning Message Service messaging, styling encapsulation, and the officially supported developer tooling and environments for LWC development.

Courseiva uses original exam-style practice questions designed for learning and revision. The goal is to understand the concepts, recognise exam patterns, and improve through explanations — not memorise copied exam dumps.

Editorial oversight:Johnson Ajibi· MSc IT Security, IEEE Senior Member
20 questionsDomain: User Interface

What the exam tests

What to know about User Interface

Be able to build and compose Lightning Web Components: wire data, handle lifecycle hooks correctly, pass styling through slots, and publish or subscribe with Lightning Message Service. The single most important thing is importing the correct modules and using the right lifecycle hook for each task.

Importing the lightning/messageChannel module from lightning/messageService to publish LMS messages

Using ::slotted() in child component CSS to style content passed into slots

Choosing connectedCallback for initialization logic when an LWC is inserted into the DOM

Recognizing Salesforce CLI, VS Code with Salesforce Extensions, and Developer Edition orgs as supported LWC tooling

Watch out for

Common User Interface exam traps

  • ▸Confusing connectedCallback with renderedCallback, then running DOM-dependent logic too early or repeatedly on every render
  • ▸Trying to style slotted content from the parent with plain selectors instead of ::slotted() inside the child
  • ▸Importing the wrong LMS module, such as messageService alone, when publishing requires the message channel module

Practice set

User Interface questions

20 questions · select your answer, then reveal the explanation

A Lightning Web Component needs to communicate an event to a grandparent component that is several levels up in the DOM tree. Which mechanism should be used?

Question 2mediummultiple choice
Read the full User Interface explanation →

A developer is writing an Aura component and needs to handle an event fired by a child component. Which attribute is required in the aura:handler tag on the parent component?

Question 3mediummultiple choice
Read the full User Interface explanation →

An LWC component uses a wire adapter to fetch account records. The developer needs to update the parameters passed to the wire adapter dynamically based on user input. How should this be implemented?

Which tag is used in Visualforce to iterate over a collection of records and display them in a table?

A developer is building an Aura component and needs to ensure that a client-side controller method executes after the component's DOM has been fully rendered. Which Aura lifecycle event or method should be utilized?

A developer is creating a Lightning Web Component and needs to style a child component from a parent component across the shadow DOM boundary. What feature enables custom styling hooks?

Which annotation must be used on an Apex method to make it available for use with the @wire service in a Lightning Web Component?

Question 8mediummultiple choice
Read the full User Interface explanation →

A developer is building a Visualforce page and wants to execute an action method on the controller when a user clicks a button, without performing a full page reload. Which component should be wrapped around the area to be updated?

Which base Lightning component should be used in an LWC to display a standard button?

Question 10easymultiple choice
Read the full User Interface explanation →

Which SLDS grid class should be used to create a flexible container where items wrap automatically onto multiple rows?

Question 11easymultiple choice
Read the full User Interface explanation →

What is the maximum number of view state bytes allowed in a Visualforce page before Salesforce throws an error?

Question 12mediummultiple choice
Read the full User Interface explanation →

A developer wants to prevent sensitive fields from being included in the Visualforce view state to reduce size. Which keyword should be added to the field declaration in the controller?

Question 13easymultiple choice
Read the full User Interface explanation →

Which base Lightning component is used to show a progress indicator or spinner in LWC?

Question 14mediummultiple choice
Read the full User Interface explanation →

A developer writes an Apex controller for a Visualforce page and wants to paginate through a large list of records using standard controller methods. Which property should be used?

Question 15hardmultiple choice
Read the full User Interface explanation →

A developer is configuring a Lightning Web Component to be used as a Quick Action on a record page. Which target configuration must be added to the component's metadata file?

Question 16easymultiple choice
Read the full User Interface explanation →

Which tag is used in Visualforce to embed JavaScript code directly inside the page?

Which TWO tools or features are recommended for styling Lightning Web Components according to best practices? Choose 2 answers.

Which TWO configuration files or metadata elements are required when creating a Lightning Web Component? Choose 2 answers.

Which THREE features or capabilities are supported by the Lightning Message Service (LMS)? Choose 3 answers.

Which THREE actions should a developer take to optimize Visualforce view state performance? Choose 3 answers.

Free account

Track your progress over time

Create a free account to save your results and see which topics improve across sessions.

Focused User Interface sessions

Start a User Interface only practice session

Every question in these sessions is drawn from the User Interface domain — nothing else.

Related practice questions

Related SALESFORCE-PD1 topic practice pages

Move into related areas when this topic feels solid.

Frequently asked questions

What does the SALESFORCE-PD1 exam test about User Interface?
Be able to build and compose Lightning Web Components: wire data, handle lifecycle hooks correctly, pass styling through slots, and publish or subscribe with Lightning Message Service. The single most important thing is importing the correct modules and using the right lifecycle hook for each task.
How should I use these practice questions?
Select your answer before revealing the explanation. Then read why each option is right or wrong — this active recall approach builds retention far faster than re-reading notes.
Can I practise just User Interface questions in a focused session?
Yes — the session launcher on this page draws every question from the User Interface domain. Use a 10-question session first to gauge your baseline, then move to 20 or 30 once the weak spots are clear.
Where can I practise other SALESFORCE-PD1 topics?
Use the topic links above to move to related areas, or go back to the SALESFORCE-PD1 question bank to see all topics.
Are these real exam questions or dumps?
These are original practice questions written to test the same concepts the SALESFORCE-PD1 exam covers. They are not copied from any real exam or dump site.