Get Ready for the Hands-on Challenge
Learning Objectives:
After completing this unit, you’ll be able to:
- Prepare your playground with metadata and data so that you can implement the lightning-record-picker in Unit 3.
In our upcoming hands-on challenge, you’ll revisit the scenario from the LWC Specialist Superbadge. All of your stakeholders are thrilled with the application you delivered. When you heard about the lightning-record-picker, you couldn’t help but think about how it could be used to provide an additional way for customers to search the boat inventory. Your plan is to build a proof of concept in your own playground, reveal it during your next meeting, and convince your team to integrate it into the full application.
Create a new Trailhead Playground now to follow along and try out the steps in this module. Scroll to the bottom of this page, click the playground name, and then select Create Playground. It typically takes 3–4 minutes for Salesforce to create your Trailhead Playground.
Launch the org you'll use for the hands-on challenge, then do the following.
- Install the same unlocked package (
04t6g000008ateoAAA
) that you used for the Superbadge. It contains the schema you need to build your proof of concept. If you have trouble installing this unlocked package, follow the steps in Trailhead Playground Management. - Create a Lightning web component.
- Name:
boatPicker
- Replace the contents of
boatPicker.js
with the following code, which uses wire service to populate aboatDetail
property and includes getters to make it easy to display information about the selected boat. You modify this file during the Hands-on Challenge. - Replace the contents of
boatPicker.html
with the following, which includes alightning-record-picker
. You modify this file during the Hands-on Challenge as the picker has not yet been fully configured. - Create a file
boatPicker.css
to style the component.
- Name: