SALESFORCE-PD1 User Interface Practice Question
A Lightning Web Component needs to communicate an event up to a grandparent component that is nested two levels above. What is the best practice to achieve this in LWC?
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Use standard browser CustomEvent with bubbles: true and composed: false
Custom events in LWC bubble up the DOM tree by default when constructed with { bubbles: true, composed: false }, allowing parent and grandparent components to listen for them.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Use the pubsub utility pattern by importing a shared JavaScript pubsub library
Why it's wrong here
Incorrect. While pubsub works, native DOM event bubbling handles parent-child-grandparent communication without extra libraries.
- ✗
Use a global Lightning Message Service context to broadcast the event across components
Why it's wrong here
Incorrect. Lightning Message Service is meant for communication across the entire DOM, including unrelated components, but custom events are simpler for hierarchical parent-child-grandparent relationships.
- ✓
Use standard browser CustomEvent with bubbles: true and composed: false
Why this is correct
Correct. Setting bubbles: true allows the event to traverse up the DOM tree to parent and grandparent components.
- ✗
Dispatch an Aura Application Event from within the LWC container
Why it's wrong here
Incorrect. Aura Application Events cannot be dispatched directly from Lightning Web Components.
About these practice questions
This SALESFORCE-PD1 question is part of Courseiva's 488-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →
JA
Written and reviewed by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
Last reviewed August 2026 · checked against the official Salesforce exam blueprint
This SALESFORCE-PD1 practice question is part of Courseiva's free Salesforce certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the SALESFORCE-PD1 exam.