5

I created one simple LWC component and when I tried to add it in Lightning App Builder I'm not able to see it. So how to add LWC in lightning app builder.

1
  • For this, you have make some change in the component meta xml file. Mar 19, 2019 at 8:26

3 Answers 3

8

To make an LWC available in the app builder you will have to set the correct values in the configuration file of the component.

You can find all the details on this link: https://developer.salesforce.com/docs/component-library/documentation/lwc/lwc.use_config_for_app_builder

10

First you need to in target tag where you want to expose your component in meta.xml file like below -

<?xml version="1.0" encoding="UTF-8"?>
<LightningComponentBundle xmlns="http://soap.sforce.com/2006/04/metadata">
   <apiVersion>45.0</apiVersion>
   <isExposed>true</isExposed>
   <targets>
       <target>lightning__AppPage</target>
       <target>lightning__RecordPage</target>
       <target>lightning__HomePage</target>
   </targets>
</LightningComponentBundle>

And then in visual studio, right click on component folder name and select "SFDC: Deploye source to org" command. After deploy it will be visible in app builder.

0

Ensure <isExposed>true</isExposed> is set correctly, or else it will not show in Lightning App Builder.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .