You need to sign in to do that
Don't have an account?

Editing Lightning Web Component
I am new to LWC and cant seem to figure out how to open the source code for LWC. Aura can be opened in the dev console but from what i understand this is not possible with LWC.
Is it possible to open a LWC source code from within the org? I have a LWC that was developed by someone else that needs editing. How can I access the source code?
Is it possible to open a LWC source code from within the org? I have a LWC that was developed by someone else that needs editing. How can I access the source code?
Step 1. Go to workbench and login.
https://workbench.developerforce.com/login.php
Step 2. Click on retrieve button.
Step 3. click on "Choose File" button and upload package.xml file.
package.xml:
Step 4. click on next and retrieve metadata, it will give you all the LWC components exist in your org.
Step 5. click Download ZIP File.
Regards,
Soyab
All Answers
You can create a new project with Manifest in VS code. After authorizing your org, retrieve metadata from Org, you will get the whole code in force-app --> main --> default --> lwc.
The manifest file should be like :
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">
<types>
<members>*</members>
<name>ApexClass</name>
</types>
<types>
<members>*</members>
<name>ApexComponent</name>
</types>
<types>
<members>*</members>
<name>ApexPage</name>
</types>
<types>
<members>*</members>
<name>ApexTestSuite</name>
</types>
<types>
<members>*</members>
<name>ApexTrigger</name>
</types>
<types>
<members>*</members>
<name>AuraDefinitionBundle</name>
</types>
<types>
<members>*</members>
<name>LightningComponentBundle</name>
</types>
<types>
<members>*</members>
<name>StaticResource</name>
</types>
<version>46.0</version>
</Package>
Step 1. Go to workbench and login.
https://workbench.developerforce.com/login.php
Step 2. Click on retrieve button.
Step 3. click on "Choose File" button and upload package.xml file.
package.xml:
Step 4. click on next and retrieve metadata, it will give you all the LWC components exist in your org.
Step 5. click Download ZIP File.
Regards,
Soyab
After being arrested, one must post bail (https://www.atlantisbailbonds.net/) to be released or wait to see a judge and ask for release (https://www.atlantisbailbonds.net/) on your word.
This is a useful discussion! I followed the steps above and managed to retrieve data from my org but I can't figure out how to edit (and find in the first place) the Article Content component that displays Salesforce Articles (part of the Knowledge product) on Communities/Sites. I need access to the HTML and JavaScript, I think, to tweak the behaviour of images displayed as part of the 'Article Content' component. I am not finding the component in question under the LWC folder, nor anywhere else (components, pages folders etc). Is this possible at all?
OMG, Salesforce Advanced Code Searcher (https://chrome.google.com/webstore/detail/salesforce-advanced-code/lnkgcmpjkkkeffambkllliefdpjdklmi" target="_blank)--which was already a great utility--has an "LWC Editor" tab built right into it:
Big props to Sameer Miraj and this wonderful addition (https://jungleeforce.com/category/salesforce-2/lwc/)!