You need to sign in to do that
Don't have an account?
Lightning web component not showing in lighting home or app page
Hi
I am following the lighting web component trailhead (https://trailhead.salesforce.com/content/learn/projects/quick-start-lightning-web-components/create-a-hello-world-lightning-web-component ).
I created the web component, but when i try to add it to the home component, the custom web component is not showing and cannot add it to the home page. The helloworld.js-meta.xml file is same as what metioned in the trailhead account.
I am doing this in my trailhead playground. Any help on this will be highly appreciated
I am following the lighting web component trailhead (https://trailhead.salesforce.com/content/learn/projects/quick-start-lightning-web-components/create-a-hello-world-lightning-web-component ).
I created the web component, but when i try to add it to the home component, the custom web component is not showing and cannot add it to the home page. The helloworld.js-meta.xml file is same as what metioned in the trailhead account.
I am doing this in my trailhead playground. Any help on this will be highly appreciated
Greetings to you!
+1 @Raj
Please make sure you are using the latest version of salesforcedx. To work with Lightning web components, you need version 45 or greater of the Salesforce CLI. Check the installed version.
sfdx plugins --core
NOTE: If you had a prerelease version of the CLI installed, run this command to update it.
sfdx plugins:install salesforcedx@latest
You can see these components in your org using the tooling API query from the dev console. Check the tooling checkbox in the dev console.
The below query should show you if your org has these components:
I hope it helps you.
Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future. It will help to keep this community clean.
Thanks and Regards,
Khan Anas
All Answers
Refer this links
https://rajvakati.com/2018/12/22/lightning-web-components/
Target --> lightning__HomePage
Greetings to you!
+1 @Raj
Please make sure you are using the latest version of salesforcedx. To work with Lightning web components, you need version 45 or greater of the Salesforce CLI. Check the installed version.
sfdx plugins --core
NOTE: If you had a prerelease version of the CLI installed, run this command to update it.
sfdx plugins:install salesforcedx@latest
You can see these components in your org using the tooling API query from the dev console. Check the tooling checkbox in the dev console.
The below query should show you if your org has these components:
I hope it helps you.
Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future. It will help to keep this community clean.
Thanks and Regards,
Khan Anas
Queried the lightning resource and found that there was issue in the meta xml file which was not stored correctly. Corrected the file and now it showing under home page component.
Now i have added the component to the home page but while validating the challenge i am getting below error :
Step not yet complete in My Trailhead Playground 2
Make sure you add the 'helloWorld' Lightning web component to the default Home page.
In case someone is just getting to this thread like I am here's what I had to do to get the LWC to show up on my app & pass the challenge:
1. Copy the code as listed
2. When you get to the part where you're ready to add the component to the page click the option to "Delopy to my Domain" (this may not be the exact verbiage)
3. Set your domain name. *NOTE: Choose wisely because domain names cannot be changed except through Salesforce Support*
4. Once your domain is active click "Login" to test out the domain
5. Deploy the domain to your users
6. Go back to the "Sales" app and edit the page adding your lightning web component as instructed
7. Verify the challenge and get the points and badge :)
I hope this helps!
I am stuck on this module. Module name: Create a Hello World Lightning Web Component.
I have created helloWorld LWC as instructed and deployed in org, but LWC is not showing in the app builder. I have checked below all possible scenarios.
1. Domain deployed - Yes it is
2. <isExposed>true</isExposed> - Yes
Please find attached screenshot and guide me where I need to correct them.
I was facing the similar issue. LWC - helloWorld was not visible in App Builder.
I tried all below even tough:
1. <isExposed>true</isExposed> was done in js-meta.xml file
2. LWC was deployed to the Org also i.e. Setup > Custom Code > Lightning Component
Actual Issue was My Domain. I was seeing "Deploy My Domain" to see custom component in App Builder. Make sure.
I deployed My Domain and started seeing component.
For more details on how to deploy my domain: https://help.salesforce.com/articleView?id=environment_hub_get_started_my_domain.htm&type=5
Thank you,
Mausam Padhiyar
do u got solution for ur doubt , i am facing same problem.
can u help me
<?xml version="1.0" encoding="UTF-8"?>
<LightningComponentBundle xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>51.0</apiVersion>
<isExposed>true</isExposed>
<targets>
<target>lightningCommunity__Page</target>
</targets>
</LightningComponentBundle>
,
You need to use the js-meta.xml file as show below and push the changes
changed from false to true.
Set isExposed --> True
<isExposed>true</isExposed>
I deployed My Domain "xyz" and later refreshed my page and again putting credentials then I started seeing component.
Your solution worked for me. Thank you very much
I am so confused, I did everything as instructed and when i go to complete the step it says that the web component isnt on the home page.....But clearly it is. any suggestions?