PDI practice question 11 of 30
In terms of the MVC paradigm, what are two advantages of implementing the view layer of a Salesforce application using Lightning Web Component-based development over Visualforce? Choose 2 answers
Full set: 201 questionsIn the Model-View-Controller (MVC) paradigm, the view layer is the user interface. Lightning Web Components (LWC) offer significant advantages over Visualforce for building this layer. LWC is built on a modern, component-based architecture. This allows developers to create self-contained and reusable units of an application (D), which encapsulates their HTML, JavaScript, and CSS. This modularity improves maintainability and development speed. Furthermore, this component-based model fosters a rich component ecosystem (A), including a library of standard base components and numerous components available on the AppExchange, enabling developers to assemble complex UIs more efficiently than with Visualforce's more monolithic, page-centric approach.
B. Leg capturing via the Debug Logs Setup page: Debug logs are a platform-wide feature for troubleshooting server-side Apex code and transactions, not a specific advantage of the LWC view layer technology.
C. Built-in standard and custom set controllers: This is a defining feature of Visualforce, which uses standardController and standardSetController attributes to automatically handle data operations. LWC uses a different model based on wire services and imperative Apex calls.
1. Lightning Web Components Developer Guide, "What Is the Lightning Component Framework?": This section introduces the component-based architecture. It states, "This structure makes components self-contained. You can reuse a component on an application page, or in another component." This directly supports option D. The guide also highlights the "Component Library" and the ecosystem of pre-built components, supporting option A.
2. Lightning Web Components Developer Guide, "Compare Lightning Web Components and Aura Components": While comparing LWC to Aura, this section reinforces the benefits of a modern, standards-based component model over older frameworks, which by extension applies to the comparison with Visualforce. It emphasizes performance and adherence to web standards, which enable the creation of more robust, self-contained units (D).
3. Visualforce Developer Guide, "Standard Controllers" and "Standard List Controllers": These sections detail the standardController and standardSetController attributes, confirming that this feature is specific to the Visualforce framework, making option C incorrect as an advantage for LWC.
Keep practicing
Take the free PDI practice test
Ten exam-style questions with answers and explanations, plus the exam facts and study guides.
More questions
Other PDI practice questions
- Question 1What can be used to override the Account's standard Edit button for Lightning Experience?
- Question 4Universal Containers (UC) wants to lower its shipping cost while making the shipping proc…
- Question 5A developer has an integer variable called maxAttempts. The developer needs to ensure tha…
- Question 7Universal Containers wants to back up all of the data and attachments in its Salesforce o…
- Question 8Universal Containers hires a developer to build a custom search page to help users find t…
- Question 9As part of new feature development, a developer is asked to build a responsive applicatio…
