Hot answers tagged

3

It is not correct that Salesforce will withdraw Aura Component stuff (Its not documented anywhere so unless you see in any official docs its not true). Salesforce supports both the programming model (Aura and LWC) and you can always use LWC inside aura components while other way round is not possible. Salesforce has excellent documentation on when to choose ...


3

In Order to create a component dynamically from JS, you need to declare the component a dependency in component markup Test.cmp <aura:component > <aura:dependency resource="markup://c:sample" /> <aura:handler name="init" value="{!this}" action="{!c.doInit}"/> {!v.body} </aura:component> TestController.js ({ doInit ...


3

While LWC is arguably a far superior framework, there are things you can do with Aura that you simply can't do with LWC. For example, dynamic creation of components simply by name. Or use of a component as an action. You can find the list of missing capabilities here (this could be a little out of date since it is a 2019 blog).


3

In order to include translations in your managed package, you just need to specify them in the package manifest. This is the same process as adding a custom field, object, class, etc. In order to deploy translations to a Scratch Org, the Translation Workbench must first be enabled. To do this, include the following settings in your org configuration file: ...


2

You can not directly use widget js in the lightning component. because of CSP As a workaround, you can create a VF page and call it using iframe in component VF Page <apex:page id="TwittweFeed" showHeader="false"> <apex:includeScript value="{!$Resource.twitterwidget}"/> <a class="twitter-timeline" data-link-color="#19CF86" href="...


2

In Aura, different namespaces get their own version of sessionStorage and localStorage. This separation helps avoid security/data leaks across component namespaces. While I can't find specific documentation on the matter, it makes sense that you also can't access Aura storage from LWC, or the other way around, since they technically exist in different ...


1

In Aura, you can use a Promise to wait for the result. That would look like this: callHelper: function(component,event,helper){ helper.createRecord(component,'dum1') .then(function(result) { console.log(result); }); } createRecord: function(component, recordName) { return new Promise( $A.getCallback(function(resolve, reject) {...


1

Your Apex action is called asynchronously from helper.createRecord(). It does not execute until after createRecord() itself returns, so it's not possible to synchronously return its result value to the calling method, callHelper() - and you certainly wouldn't want the code that's running in your UI to block waiting for an asynchronous function to return, as ...


1

I think you are looking for approach to develop this solution. Build An Aura-Component (in the Init Handler, You can call to APex Method, which will check for current logged in UserId by using UserInfo Class and query all accounts owned by this User ) You can then display all these accounts in a lightning datatable Now, go to Object Manager, Button and ...


1

You can just create the component dynamically, that is by using $A.createComponent() method. As per SF doc: The $A.createComponent() and $A.createComponents() methods support both client-side (synchronous) and server-side (asynchronous) component creation. For performance and other reasons, client-side creation is preferred. To use $A....


1

Looks like you just need to do two things. First, change the status: record.Status__c = 'Awaiting Approval'; ... component.find('RRLoader')... Next, you can build a Process to submit the record for approval once the status is changed to Awaiting Approval.


1

You can try standard Js way window.location.reload()


1

It's the event name with "on" prefixed. <c:my-lwc-component oncaserecordchange="{!c.handleCaseRecordChange}" /> You can read more about it in the documentation. For the moment, the Aura compiler doesn't know what events can be fired from LWC, so be sure not to have any typos, or your event will be missed. The documentation doesn't mention a way to ...


1

As per the documentation: This component is not supported in Lightning Out, Lightning communities, or the Salesforce mobile app. (my emphasis)


Only top voted, non community-wiki answers of a minimum length are eligible