1

Is it possible to change code (html, js, css) in Lightning Web Components online in Salesforce? Something like this I don't know to run it according this manual.

Because I would like to check code imported from VSCode. It seems to me that the code/component is not updated.

Elo
  • 226
  • 5
  • 19

2 Answers2

1

there is a variety of chrome extensions available to view and edit the LWC code within the salesforce. I am using the following:

To view the code only you can make use of the Salesforce Assitant extension: https://chrome.google.com/webstore/detail/salesforce-assistant/acpngnlieelljdlljmenkagbonaicccj

enter image description here

.

.

If you want to edit the code as well, then you can consider salesforce advance code searcher: https://chrome.google.com/webstore/detail/salesforce-advanced-code/lnkgcmpjkkkeffambkllliefdpjdklmi enter image description here

Jasneet Dua
  • 3,796
  • 2
  • 10
  • 15
  • Thank you, I installed Salesforce Assistant into Chrome 89, but it writes "Please wait while loading data". 10 minutes passed and nothing read. [image](https://pasteboard.co/JShK3D0.png) And Salesforce advanced Code searcher does not work. – Elo Mar 12 '21 at 15:28
  • Hey @Elo, wait for some time or try switching between classic and lightning mode once. if it does not work then try logging into your org again. I'm using this extension since it was launched and got a similar message when used for the first time on org and after a while, it works fine.... And For Salesforce advanced Code searcher you have to authorize your logged-in org. – Jasneet Dua Mar 13 '21 at 07:25
  • Sorry man, I tried your advices, but Salesforce Assistant does not work. I logged in to Salesforce Lightning Experience and I clicked to Chrome extension the Salesforce Assistant. I waited 1 hour and it wrote "Please wait while loading data". Then I logged out. I logged in. Again clicked to the Salesforce Assistant. And I waited 1 hour and nothing to load. – Elo Mar 13 '21 at 15:38
  • Therefore switched to Salesforce Classic and I repeated the procedure. I clicked to Chrome extension the Salesforce Assistant. I waited 1 hour and it writed "Please wait while loading data". Then I logged out. I logged in to Salesforce Classic. Again clicked to the Salesforce Assistant. And I waited 1 hour and nothing to load. Sorry, I don't know how to run the Salesforce Assistant. – Elo Mar 13 '21 at 15:38
  • Chrome Extension **Salesforce Advanced Code Searcher** does not work due to authorization. When I click to [authorize](https://pasteboard.co/JSsdial.png) then is an error message [Web is blocked](https://pasteboard.co/JSsdHIOt.png) – Elo Mar 13 '21 at 17:49
  • Hey @Elo, not sure what's going on there in your org man. For me it works perfectly fine. What I can suggest you now is to try extension with your developer org and see if the issue still persists. Also, there is one session setting "Lock sessions to the IP address from which they originated", try disabling it... anticipating the extension uses there own server to access the salesforce content. – Jasneet Dua Mar 14 '21 at 13:16
  • are you using any add blocker extension? coz error suggests that your browser is blocking get the access – Jasneet Dua Mar 14 '21 at 13:25
  • 1
    **Salesforce Assistant** and also **Salesforce Advanced Code Searcher** is working now. Just turn off Incognito mode in Chrome :) It works, thank you. – Elo Mar 17 '21 at 09:37
0

Currently, you can't "import code online".

To check if your code been deployed correctly you can use chrome devtools and see if your files been deployed and used. There is a cache machanizam also which you can disable -will reduce performance https://www.salesforcecodecrack.com/2019/09/disable-browser-cache-during-lightning.html

For more info regarding debugging LWC check out this article: https://developer.salesforce.com/blogs/2019/02/debug-your-lightning-web-components.html

MenashYA
  • 21
  • 5
  • Ok, code cannot be modified online. And is it possible view structure of files html, js, css? Because I see only components. – Elo Mar 12 '21 at 08:10
  • Same... You can use this Chrome extension in case you "have it" https://chrome.google.com/webstore/detail/salesforce-advanced-code/lnkgcmpjkkkeffambkllliefdpjdklmi ofcourse you should check your org policy for those kinds of extensions since it requests an access – MenashYA Mar 14 '21 at 12:07