Difference of Lightning Web Component and Lightning Web Component Open Source

I found Lightning Web Component Open Source on the way of research Lightning Web Component.

I could find their difference only about merit of open source, but I want to know wether I can use LWC-open source as like LWC or not.

Is there any unusable lightning tag?

Is there any inconvenience point?

Is there any web site which is explaining about these differences?

I’m afraid of encounter unexpected specification change.

Answer

The core benefit of using Lightning Web component Open source is you can use outside salesforce platform. You can use it along with third party lib or other components in your web application.

With Lightning web component on the salesforce platform you get below benefits

  • Lightning base components are available and can reduce your development time as they offer declarative components. Note these base components are not available for open source
  • Lightning design system is baked into the base components
  • Lightning components build on the platform use locker services to establish great security
  • All third party lib need to be served from static resource which provides security benefits
  • Using data from the platform is lot easier as these provide excellent support for working with apex and lightning data service

If you are building a salesforce app for salesforce platform use lightning web component and leverage all benefits it provides.

While if you are planning to build an app that should reside outside salesforce , salesforce web components open source is a great choice.Note that you wont have access to base components that salesforce provides and to get data from salesforce you will use salesforce REST API.

There is a great Trailhead Trail for the Lightning Web components open.

NOTE- Converting lightning web component built using open source lightning web component to salesforce specific lightning web component is relatively straight forward as well and this Trailhead module covers in detail.

Attribution
Source : Link , Question Author : Hayato , Answer Author : Mohith Shrivastava

Leave a Comment