Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [locker-service]

Locker Service is a set of new security features for Lightning Components.

0
votes
1answer
14 views

Uncaught SecureElement.innerHTML cannot be used with BODY elements! when using dhtmlxGantt in Lightning Component

I am trying to use dhtmlxGantt inside a Lightning Component. CMP <aura:component implements="flexipage:availableForAllPageTypes"> <ltng:require styles="{!$Resource.dhtmlxgantt_css }" /&...
-1
votes
0answers
41 views

Alternative Frameworks using LWC [duplicate]

Has anyone tried implementing React/Vue using Lightning Web Components yet? I know it was semi-possible using the previous framework and would be curious to see how it might make LWC better than its ...
-1
votes
0answers
78 views

React with Lightning Web Component [closed]

Has anyone got a chance to try React with Lightning Web Component already ? It seams it suppose to be easy based on LWC example. I want to know the best ways and how possible and easy it will be for ...
1
vote
1answer
43 views

Blocked by CORS policy: No 'Access-Control-Allow-Origin' header on the requested resource

I am trying to use a Google Charting library inside a Lightning Aura Component. Component <aura:component implements="flexipage:availableForAllPageTypes"> <ltng:require scripts="{!$...
1
vote
1answer
21 views

invoking .click() function in lightning component

Client needs demand that we don't use the default SLDS style for the file uploads. Basically, have a specific icon we have to use for uploads which isn't the SF one. In prior releases, we were able ...
2
votes
1answer
42 views

How can you get the caret position when working from an event?

Looking at the Locker documentation they list selectionStart as being a valid attribute, but I can't find a way to access it. I am trying to write an input masking utility, and everything works fine ...
3
votes
0answers
41 views

Using postMessage across different namespaced components

In Salesforce, postMessage is mainly used for communicating in between Visualforce and Lightning components Communicating between Lightning Components and Visualforce Pages Window.postMessage() ...
0
votes
3answers
80 views

access Target Element in Proxy

i have the following line: var childCmp = cmp.find("lookupCmp"); My Lightning component API Version is 44.0 lookupCmp is a custom lightning component. When i run this line i get: childCmp = ...
3
votes
1answer
46 views

Why ECMAscript 6 Object.freeze not working with Locker Service?

We have a library we created using ECMACScript 6 that we transpiled using babel that worked perfectly with a VisualForce page. Migrating this library to work with Locker Service I found that Object....
0
votes
2answers
60 views

Alternative for javascript window method for visualforce pages in lightning

With the lightning readiness report there is mention that javascript window method won't perform as supposed to in Lightning. Salesforce documentation suggest sforce.one navigation methods to replace ...
6
votes
1answer
268 views

Locker service and lightning web components

Is there any documentation yet on how locker service fits in with lightning web components? If yes, What are the implications of locker service on lightning web components? What are locker service ...
3
votes
0answers
101 views

Is it possible to disable mobile touch on a Salesforce community

Background I have a community page which displays a calendar by FullCalendar The calendar is in a Lightning Component. Both Salesforce Communities and FullCalendar support mobile devices. ...
0
votes
1answer
30 views

Locker Service and CSS in JS

Without trying this myself I was curious if anyone else was able to get CSS in JS to work within the confines of LockerService. At first glance it looks like styled-components might actually work as ...
1
vote
1answer
73 views

Only 1 of 3 JavaScript files load when using <ltng:require> and afterScriptsLoaded event not firing

Background I am trying to use the PageDown JavaScript library: Markdown.Converter.js - (click to view source) Markdown.Editor.js - (click to view source) Markdown.Sanitizer.js - (click to view ...
4
votes
1answer
200 views

Stripe integration for Salesforce in lightning components

We are trying to implement Stripe integration with Salesforce by using Lightning Components for payments. Stripe use an API for securely obtain the users card information. This API is for the client,...
1
vote
1answer
33 views

Multi thread in lightning component script

im looking for some method to divide thread in my lightning component JS. As far as I know is JS running on single thread. but web.Worker function can be alternative. i tried to use web.worker .. ...
0
votes
1answer
32 views

loop through components looking for data in it

im building a list that people select only a single item which works in a limited capacity but reloading or re-selecting isnt very user friendly. the basic concept is a controller retrieves selections,...
5
votes
2answers
119 views

accessing a lighning inputField lookup name client side

I am easily able to fetch a lookup ID from a inputField <lightning:recordEditForm objectApiName="Case"> <!-- the messages component is for error messages --> <...
11
votes
3answers
612 views

Lightning support for eval() in Summer 18

I thought that eval() was supported in Lightning in Summer 18. According to the release notes, it is: The eval() function is now available in Locker Service, even when Strict CSP is enabled. This ...
2
votes
1answer
122 views

Library import not working

I am trying to import a library into Salesforce Lightning using ltng:require. Problem is, when I try to use some of the objects from the library in my controller, it can't find those objects. I have a ...
1
vote
1answer
71 views

Cannot read property 'Converter' of undefined, when using StackExchange PageDown Library in Lightning Component

BACKGROUND I am trying to use the PageDown JavaScript library: Markdown.Converter.js - (click to view source) Markdown.Editor.js - (click to view source) Markdown.Sanitizer.js - (click to view ...
0
votes
1answer
30 views

Using princexml and PDFreactor in Lightning component with version 43.0

I want to know if Salesforce allows princexml or PDFreactor js library to work if locker service is enabled. This files are used to convert html to PDF
0
votes
1answer
119 views

jsPDF library does not work in Lightning components 43.0 version

I have stored jsPDF library in static resource and using it in lightning component where version is 43.0. This library does not work if LockerService is enabled.I decreased version to 39.0 and then it ...
1
vote
1answer
50 views

How to show the difference with and without locker service using lightning components?

I created one component before activation of the locker service. After that i created another component after activation of the locker service. But my doubt is how to know, what is the difference ...
1
vote
1answer
56 views

Why different orgs behave differently with supposedly same config for Locker Service

So, reading documentation regarding locker-service I get that the only way of disable it, is downgrading the api version of each component to 39 or less. Also, documentation says that there is no ...
0
votes
0answers
213 views

HTTP Form Post to external website from Lightning Component

I am working with a client to develop a managed package. Here is the requirement in brief: User clicks a button in a lightning component which is added to Contact detail page. The button click ...
3
votes
1answer
143 views

Generating a PDF from a Lightning Page with LockerService restrictions

I'm trying to generate a PDF from a Lightning Page using jsPDF. When I use the addHTML function in jsPDF I get an error (but only if locker service is enabled). The problem is in the use of ...
1
vote
0answers
138 views

Lightning Component CSP - Meta tag http-equiv for TinyMCE

I have a lightning sub component within a larger component that uses TinyMCE js library locally to provide advanced editing capabilities. The component works when I disable LockerService, by setting ...
2
votes
1answer
44 views

Why do I get a different type dependant on when I evaluate a JavaScript variable in Salesforce Lightning

I would like to understand why the typeof a JavaScript variable is different depending on where I evaluate it, even though I have't changed it. I have a object like this: var model = {} model.user = ...
2
votes
2answers
207 views

Invalid SecureWindow API, toString was blacklisted : Source Error in Lightning

I am new to Lightning. I have created Lightning component and a controller. Lightning component code: <aura:component > <ui:button press="{!c.doInit}"> <div class="testClass">...
4
votes
3answers
439 views

How to Use lightning Locker Service in sandbox

I know how to configure security model through OWD, Sharing Rules, Profiles and Roles in salesforce sandbox account but how to use Lightning Security Locker Service instead of OWD, Sharing Rules...etc ...
0
votes
1answer
116 views

lightning:actionOverride set Page Title

I've create a lightning component which implements lightning:actionOverride, for use as a custom new record page. I've created an object called "Custom Object" with API Name "CustomObject__c" ...
1
vote
2answers
125 views

what is the difference between lightning with locker service and without locker service using in components?

I know little bit knowlege of lightning components. I am new to Lightning locker service. What is the difference between lightning with locker service and without locker service? how to know it is ...
6
votes
3answers
416 views

How to unproxy LockerService wrapped data for debugging via console.log()?

In Lightning Components I love to use console.log() to get an understanding what is happening. Often there is data shown as "Proxy{}", which looks in the console like this I KNOW that there is fine ...
1
vote
0answers
54 views

lightning Component access denied from namespace

I am testing a simple lightning component which uses 3rd party js loaded as static resource. Originally I made in in a traiheadplayground. It is a sigle component and in app that only includes that ...
4
votes
3answers
186 views

How serious is this sfdx force:lightning:lint error on Array.from?

This Lightning Component code appears to work: var tab = component.get("v.tab"); var fields = new Set(); tab.qualifiedFieldApiNames.forEach(function(item) { if (item) fields.add(...
13
votes
1answer
414 views

component.find({ instancesOf : “lightning:input”}) return empty list in Summer '18

With new Summer '18 release following code returns empty list: component.find("social-security-number-form").find({instancesOf : "lightning:input"}) "social-security-number-form" is an aura:id of ...
3
votes
1answer
140 views

lightning:checkboxGroup - set checkbox indeterminate = true

I'm using lightning:checkboxGroup and I'm trying to set the state one of the individual checkboxes as indeterminate. I tried the following JS: component.find("my-chbxgroup").getElement()....
0
votes
0answers
110 views

OnclicktoDial method not working sometimes throwing error Refused to execute JavaScript URL

I' m trying to integrate openCti with 3rd party application. i've already created a call center , Lighning app and added URL to the call center where my aplication is hosted. In my Application I've ...
6
votes
2answers
268 views

Cometd not working in summer 18

We have been using cometd with pushTopic. But we facing an issue an issue in summer 18 org that handshake with cometd is failing in lightning component. if we use lightning component directly in ...
6
votes
3answers
476 views

Summer 18: SVG blocked in Lightning Components

The old approach of using a helper component to display SVG in Lightning now appears to be blocked in Summer 18. What is a bit alarming, though, is that even components marked with API version 40-42 ...
6
votes
1answer
238 views

Is it possible to mass-save many lightning:recordEditForms with only ONE button?

Im implementing an line item editor for the "Order" SObject and want give lightning:recordEditForm with lightning:inputField a try for this. What I have so far is an edit for the order combined with ...
2
votes
2answers
113 views

global scope where all components can access these values

I am writing an Lightning component where I am getting some values form Salesforce backend through Apex Controller. I need these values to be referred across all other components (components which ...
0
votes
1answer
179 views

jQuery parseXML() no longer works since Summer '18

Since the Summer '18 patch the jQuery parseXML() is now throwing a "Invalid XML: .." error message. Sample code: try{ var xml = "<node>test</node>"; var xmlDoc = $.parseXML(xml); ...
1
vote
0answers
28 views

Locker Service and passing the response from a server action into another namespace

For a little while, I've been using a generic Lightning component with an aura:method to handle server responses. It looks at response.getState() to see if there are any errors, and can then display ...
1
vote
2answers
70 views

How to get lightning component iteration variable with lockerservice

I have a lightning component that looks like this: <aura:iteration items="{!v.categories}" var="category"> <li data-category-id="{!v.category.Id}"> <ui:inputCheckbox change="...
3
votes
1answer
435 views

New CSP violation spontainiously happening in lightning

I have some code in a visualforce page that used a custom js library to build an excel file client side from an object generated on the server side and then force the browser to download the file. ...
10
votes
2answers
553 views

Scheduler Javascript Library / Component that works in Salesforce Lightning with LockerService

Please, could someone recommend a Scheduler Javascript Library / Component which will works in Salesforce Lightning with LockerService? Something like this:
1
vote
1answer
151 views

Latest version of jQuery that works in Salesforce Lightning with LockerService?

I'd like to know what is the most recent versions of jQuery and jQuery-UI that works with Salesforce Lightning with LockerService on?
0
votes
1answer
155 views

Locker Service Compatibility with CMS Connect

We are doing some work on integrating AEM as the CMS connection in a Salesforce Lightning Community page using CMS Connect and the Lightning Builder but have run into some issues with the Locker ...