Questions tagged [lwc-oss]

Lightning web components OSS, referred to as Lightning web components Open Source is a framework that allows building custom elements with HTML, JavaScript, and CSS. Lightning Web Components uses standard HTML, modern JavaScript (ES6+), and the best of native Web Components and can be used to build web apps on or off (ex website hosted on Heroku/Netlify or PWA app hosted outside Salesforce) Salesforce platform.

Filter by
Sorted by
Tagged with
-1 votes
0 answers
14 views

FSL LWC uploading Images FROM Android Shared folder

I have the following "Android case": A mobile app takes pictures and stores them locally, then I have to upload those images from a FSL LWC quick action, the question is: is it posible to ...
Carlos Torres's user avatar
0 votes
0 answers
38 views

Facing issue while installing and running LWR LWC OSS in my windows machine

I have installed LWC OSS from the official site https://lwc.dev/ Here is the steps I followed : Made sure I have node and npm installed Created a lwr project : npm init lwr@latest Installed ...
Akash Musale's user avatar
-1 votes
1 answer
53 views

How can we make the server side API details configurable after build in LWC OSS single page application?

I am trying to build an LWC OSS app. The Sever side logic is written using a express JS, which is currently running in local host. I need to create a build of my LWC oss application and need to make ...
Vivek M's user avatar
  • 52
2 votes
1 answer
200 views

How can I compile a LWC to use it as a standard web component via customElements.define()?

I'm trying to compile a LWC to a standard web component, so that after importing it I could just use it as any standard HTML tag: <html> <script type="module" src="./...
Fabien Taillon's user avatar
0 votes
0 answers
176 views

LWCs that can work offline with JS library?

Is there a way to have LWC components that can work offline on Salesforce mobile? (The components in question will render diagrams etc). So far I have only found this.
Atlas Can's user avatar
  • 1,847
0 votes
0 answers
529 views

I want to show lwc datatable in a nexted table row which is being iterated by a parent component, but my table is coming in column instead of row

I have created 3 components, 1. grand parent component : in that component, I am adding a table header and the view and then in the second component my table rows are coming via lwc iteration and in ...
Vivek Kumar's user avatar
0 votes
2 answers
1k views

lightning-input type=datetime [Unable to set / consider the locale time for the validation as per the Locale of the User]

.html snippet (LWC Component) .js snippet (LWC Component) import { LightningElement, track } from 'lwc'; export default class DateTimePickerLightningInput extends LightningElement { @track today; ...
Salesforce Developer's user avatar
1 vote
0 answers
56 views

LwcWebpackPlugin with AliasModuleRecord for lwc.dev isn't loading HTML file for component

I use LwcWebpackPlugin to load Lightning Web Components. Everything works fine but because I want to load compoennts from 'lwc' direcotry the namescape won't work. I must get components from /lwc ...
Piotr Bokiej's user avatar
0 votes
1 answer
160 views

Filter search in LWC

HTML <template> <lightning-card> <div class="slds-box slds-theme_default"> <div class = " slds-grid slds-size_12-of-12"> ...
sunny roxx's user avatar
1 vote
1 answer
182 views

Where are Lighting Web Runtime OSS built static files?

When using LWR OSS, I'm running npm run dev as stated in the doc, however I don't see any built files. When I was using create-lwc-app (deprecated), I could see all files generated under dist folder. ...
Fabien Taillon's user avatar
3 votes
1 answer
164 views

What's the expected label file format for Lightning Web Runtime OSS?

In the Lightning Web Runtime OSS documentation, in the "Use Module Providers" section, I can see "Your application components can now statically import labels sourced from JSON files in ...
Fabien Taillon's user avatar
1 vote
1 answer
189 views

How to add a proxy middleware in the lwr server?

I have built a simple web app using the LWR OSS(same as lwc-recipes-oss), I want to use the JSForce in this project to connect to Salesforce API. Because of the CORS policy, I am not able to fetch ...
Rahul Gawale's user avatar
  • 11.8k
0 votes
0 answers
353 views

Is it right way to check CRUD Permission in LWC?

import { LightningElement, wire } from 'lwc'; import { getObjectInfo } from 'lightning/uiObjectInfoApi'; import ACCOUNT_OBJECT from '@salesforce/schema/Account'; export default class CheckPermission ...
John's user avatar
  • 1
0 votes
1 answer
845 views

web application using open-source LWC and node.js

I'm trying to create web app using open-source LWC and node.js and following the steps mentioned in this blog. My app is working till Step 2. I'm stuck in Step 3 where I need to Create a GET method at ...
salesforce Developer's user avatar
0 votes
0 answers
162 views

This is my LWC and I want some flexibility in it

I want flexibility so that in the first row it ends with 105 and in the next row it starts with 201; it means it automatically creates a row start with initials 1,2,3 and it means if it ends with 105, ...
Unknown's user avatar
0 votes
1 answer
398 views

How to over come the error :- The `innerHTML` property is available only on elements that use the `lwc:dom="manual"` directive?

On click of a div i am trying clear the content and I am making it editable. so when i try to get the innerHTML it has no issues but when i try to modify the innerHTML , i get a console error as below ...
JalilIrfan's user avatar
1 vote
1 answer
610 views

Problem while executing command npm run start on scratch LWR projects

I having an issue while running a LWR project. I am creating a scratch project using the steps shown in https://lwc.dev/ but not able to get proper output (in this case a "Hello World" text) ...
Manan Trimbakey's user avatar
1 vote
0 answers
250 views

How to use an lwc oss web component in a vue project for example?

I would like to import this lwc oss component: https://www.npmjs.com/package/lwc-clock-utils in a vue project. May someone help me pointing how to properly import the package?
Renatho Azevedo's user avatar
2 votes
1 answer
5k views

html select is not working when manipulated from js

I am currently writing an LWC OSS project and am currently confused about some reproducible side-effects on a <select>. The element can be "injected" from outside, by setting the value ...
itsmebasti's user avatar
  • 6,349
4 votes
2 answers
690 views

LWC OSS: How to set properties of components imported dynamically?

I am trying create components dynamically with the help of lwc:dynamic directive in LWC OSS. I am able to create those comments dynamically, but not able to set the properties to them. For each ...
Rahul Gawale's user avatar
  • 11.8k
0 votes
1 answer
2k views

this.querySelector || this.getElementsByClassName not working in LWC OSS

I am creating an application on LWC OSS. As Lightning Toasts are not available on LWC OSS, I am trying to create a notification component that can show the notifications. I am just trying to run the ...
Somya Tiwari's user avatar
1 vote
1 answer
484 views

Not able to deploy LWC OSS app to Heroku

Getting the following error when I am trying to deploy an LWC OSS app to Heroku, I tried to deploy my app which had customizations got the same error, but now this is an LWC OSS fresh installation ...
Somya Tiwari's user avatar
1 vote
2 answers
501 views

Could Not Find module "lightning/ariaObserver" LWC OSS

I am trying to implement a project with LWC OSS, when trying to import lightning-input I am facing the following error. I tried to import the lightning-button and I was able to import the same ...
Somya Tiwari's user avatar
0 votes
1 answer
292 views

Edit Lighting Web Component and retrieve code

My org recently had a lighting web component written launched into production. Unfortunately, the team we outsourced this to left off a necessary field. I would like to edit this code to include this ...
Mack Brooks's user avatar
0 votes
0 answers
91 views

Unable to create LWC recipe component in the Webcomponents.dev playground

I am trying to create the LWC OSS components in the https://webcomponents.dev/. I created the hello.html with the below code. <template> <ui-card title="Hello"> <...
Prolay Chaudhury's user avatar
0 votes
1 answer
329 views

Creating LWC OSS app using Lightning Web Runtime

Salesforce is deprecating create-lwc-app. Instead, Salesforce is suggesting to create an LWC OSS app using Lighting Web Runtime. The command to create the LWC OSS app is npm init lwr I ran npm init ...
Prolay Chaudhury's user avatar
0 votes
0 answers
85 views

Lightning Web Component Open Source

When I try to create the project with lwc oss it comes to nothing, stops at the attached image part and does not progress. Do you know why this could be the problem?
Martin Aguilera's user avatar
0 votes
0 answers
384 views

jsforce logout functionality

In one of my node project, I am using jsforce oauth2 to connect to Salesforce. This is working nicely. Below is the code I am using for logout functionality. This is also working fine without any ...
Somnath Paul's user avatar
-1 votes
1 answer
1k views

LWC Select component to select value based on specific value in JS not HMTL

I have code right now below that selects the value based on the selectedindex of 0 or since I only have two options. What I am trying to figure out is how to set the select value instead of by 0 or 1 ...
Drake's user avatar
  • 37
0 votes
1 answer
3k views

LWC Select component how to default value in JS not HTMl

I am trying to default the value of the select to a specific value based on a condition so I cannot just put selected in the html. I need JS code that will automatically update it. For this though I ...
Drake's user avatar
  • 37
1 vote
1 answer
239 views

lwc-oss lightning-base-components jest tests

I am working on an lwc-oss project and found reference to lightning-base-components npm package in a salesforce blog post. https://developer.salesforce.com/blogs/2020/12/build-connected-apps-anywhere-...
Dave C's user avatar
  • 21
0 votes
1 answer
795 views

How to get value from Case.Account.Primary_Email__c and Case.ContactEmail from case recordID and autopopulated in To field on email page in lwc?

Controller_consumerSendEmail.cls public with sharing class Controller_consumerSendEmail { @AuraEnabled(cacheable=true) public static void sendEmailToController(String toSend, String subject){ ...
Shweta Mishra's user avatar
0 votes
1 answer
385 views

Wrap LWC OSS App for Mobile

Is there a way to make an LWC "OSS" app obviously running on Node.js as a Mobile application? (i.e. Cordova). I see you can create an LWC Hybrid app running your "Salesforce" LWC ...
paul.payne's user avatar
0 votes
1 answer
3k views

Parsing JSON string value returned from APEX in LWC

I am receiving JOSN string in the following format {"data":{"meta":{"resultCode":null,"message":null},"data":[{"code":"$RFG","...
Mangoski's user avatar
  • 208
0 votes
2 answers
3k views

LWC : onchange Handler not getting fired when @track attribute is changed

I have two lightning input in a simple LWC component having respective onchange handlers and being @tracked with respective attributes. Second onchange handler is getting fired when I update second @...
Saksham Mahendru's user avatar
1 vote
1 answer
688 views

LWC Build Files Explaination

I have been trying to research this on my own, but I can't find a simple explanation that tells me the difference between the following 2 files: lwc.config.jsonhttps://developer.salesforce.com/blogs/...
Bryan Anderson's user avatar
3 votes
1 answer
423 views

LWC OSS - Can I use an component I build in LWC OSS within Salesforce?

I am likely not understanding some parts of the potential of LWC OSS but is it possible to built an application/ component in LWC OSS and then utilize it within Salesforce. Or is this only for ...
user96190's user avatar
0 votes
2 answers
7k views

How to Show/Hide button based on Profile in Salesforce LWC?

I have develop LWC component which is normally used by normal users. In that lightning web component button is there as below. <lightning-button slot="actions" label="Deactivate"...
lochana's user avatar
  • 27
0 votes
1 answer
341 views

Call API from LWC OSS

I created an LWC OSS app with express server using npx create-lwc-app: Do you want to use the simple setup? Yes Package name for npm demo-app Select the type of app you want to create Standard web ...
Badbaxx's user avatar
  • 365
1 vote
1 answer
598 views

Is it possible to use LWC-related npm modules & webpack to leverage the LWC framework with Cloudflare Workers?

I am hoping to use the LWC framework with Cloudflare Workers in JavaScript, but running into some issues. It seems like Wrangler ignores node_modules so I was hoping to use webpack in order to load ...
Max Goldfarb's user avatar
2 votes
1 answer
261 views

How to Customize Base Components?

I want to use a custom icon with a button. The standard lightning-button could not be used because it does not support custom icons. So I looked into the base-components-recipes repository as the docs ...
Eduard's user avatar
  • 5,037
0 votes
1 answer
587 views

How we can achieve navigation to another page in LWC OSS?

I created my first app using LWC OSS. I want to achieve the navigation from one page to another (url in the browser should change) I have two files created in LWC OSS app first file at src/client/...
Navaprasad Reddy Ande's user avatar
1 vote
2 answers
420 views

LWC OSS Import External Google API's

I am trying to utilize Google API's in a LWC component. I am able to do a fetch in my component to a hosted API endpoint that utilizes the google API's and returns a list of Google Drive files via ...
paul.payne's user avatar
2 votes
1 answer
582 views

How to configure Socket.io to work with LWC OSS?

I am trying to use socket.io library with LWC OSS and followed the below steps: Created LWC OSS app using the command npx create-lwc-app my-app Installed socket.io library using the command npm ...
javanoob's user avatar
  • 8,767
3 votes
1 answer
125 views

In LWC OSS what is this.allsession while assigning to arrya

I am learning LWC OSS and in the trailhead, I am unable to understand, the use of this.allSessions in the below code while assigning the result to the array variable of "sessions = []" ...
Haroon Khan Mohammed's user avatar
2 votes
1 answer
506 views

Unable to use lwc:dynamic directive in LWC component

How do I enable the lwc:dynamic directive or is it tied to certain release of Salesforce?
ashwin murugadass's user avatar
0 votes
1 answer
141 views

LWC OSS Build Command

I'm trying to build an LWC OSS project for production, but I can't figure out where the 'npm run build' command builds the bundled resource. I don't see anything obvious in the configs or on either of ...
Scott Morrison's user avatar
7 votes
1 answer
2k views

Lightning Open source use of base components

A few days back an npm package for base lightning components was released Base Lightning Components With this I am expecting to use base lightning components like my favorite lightning-datatable in a ...
Omkar Deokar's user avatar
0 votes
1 answer
632 views

Query Selector is not working when I am putting inside renderedCallback Lifecycle hook in Lightning Web Component

I am creating a variable crashride and doing querySelector inside renderedcallback then I am using that variable inside another function. But if I directly say this.crashride inside the function ...
smriti sharan's user avatar
0 votes
0 answers
1k views

JSForce GET Request Issue

I am using a LWC Open source app to make a GET request to my Salesforce Org. I want to get the resource at : https://na111.salesforce.com/services/data/v42.0/sobjects/EventLogFile/0AT3h00000PE85uGAD/...
Apex Srinivas's user avatar