Let’s talk about Local development server. Each day we will reveal our “tip of the day” regarding the #Winter20 release.
What’s new?
When you develop Lightning Web Components you can now see live changes as soon as you save your code in your local environment!
To use the local LWC development server, you have to follow three simple steps:
- Open the terminal and install the local development server
sfdx plugins:install @salesforce/lwc-dev-server
- Start the server by running this command
sfdx force:lightning:lwc:start
- Finally, go check it out at http://localhost:3333, you will find a list with the components in your sfdx project:
We love it!
As a developer, I used to spend a lot of time pushing my components to an org, testing them, finding bugs, correcting the code, pushing it one more time, testing again, and so on.
This tool saves me a lot of time!
Now, there is no need to deploy to an org to preview your component. The server will also show any errors you may have made during development. And the best part is that you can use data from your org to test the component in local!
You can learn more about this feature in the Release Notes here.
Want to learn more? Check out our next article Permission sets groups and follow us on Linkedin!