Does more logic on Client side reduces the lightning performance?
Clash Royale CLAN TAG#URR8PPP
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty margin-bottom:0;
up vote
1
down vote
favorite
I am just struggling to understand on this as I develop a lightning component. I have object rows from apex controller which gets displayed on the component using <table>
, <tr>
and <td>
tags. I have written most of the logic on the component itself like disable 'select' checkbox if rec.status = completed
, enable 'select' checkbox for rec.status = Open
, use of different checkboxes and inputfields using <aura:if>
. I was just suggested that we should implement all such kind of logic on the backend (apex) and we should use the front end just to display the records.
Does this way of doing reduces the performance of the lightning component?
lightning-components performance javascript-controller
add a comment |Â
up vote
1
down vote
favorite
I am just struggling to understand on this as I develop a lightning component. I have object rows from apex controller which gets displayed on the component using <table>
, <tr>
and <td>
tags. I have written most of the logic on the component itself like disable 'select' checkbox if rec.status = completed
, enable 'select' checkbox for rec.status = Open
, use of different checkboxes and inputfields using <aura:if>
. I was just suggested that we should implement all such kind of logic on the backend (apex) and we should use the front end just to display the records.
Does this way of doing reduces the performance of the lightning component?
lightning-components performance javascript-controller
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I am just struggling to understand on this as I develop a lightning component. I have object rows from apex controller which gets displayed on the component using <table>
, <tr>
and <td>
tags. I have written most of the logic on the component itself like disable 'select' checkbox if rec.status = completed
, enable 'select' checkbox for rec.status = Open
, use of different checkboxes and inputfields using <aura:if>
. I was just suggested that we should implement all such kind of logic on the backend (apex) and we should use the front end just to display the records.
Does this way of doing reduces the performance of the lightning component?
lightning-components performance javascript-controller
I am just struggling to understand on this as I develop a lightning component. I have object rows from apex controller which gets displayed on the component using <table>
, <tr>
and <td>
tags. I have written most of the logic on the component itself like disable 'select' checkbox if rec.status = completed
, enable 'select' checkbox for rec.status = Open
, use of different checkboxes and inputfields using <aura:if>
. I was just suggested that we should implement all such kind of logic on the backend (apex) and we should use the front end just to display the records.
Does this way of doing reduces the performance of the lightning component?
lightning-components performance javascript-controller
lightning-components performance javascript-controller
edited 15 hours ago
David Reed
22.8k41641
22.8k41641
asked 15 hours ago
Kanikala
797
797
add a comment |Â
add a comment |Â
3 Answers
3
active
oldest
votes
up vote
5
down vote
Lightning Component Framework is optimized for performance. So unless and until you have things really going bad, you should be good if you implement your component using Lightning Components Performance Best Practices.
Then Lightning component framework is all about building rich UI applications utilizing more of client side features. So if you really donâÂÂt use the client side features, then you will end up under-utilizing the framework.
One of the significant considerations for performance in any framework is to reduce server trips. So as long as you are efficiently handling your client side components without making unwanted server calls, you are in fact doing it the right way.
Here are few of the excerpts which you can find on documentation on Lightning Component Framework.
The benefits include an out-of-the-box set of components, event-driven architecture, and a framework optimized for performance.
Uses a stateful client and stateless server architecture that relies on JavaScript on the client side to manage UI component metadata and application data. The client calls the server only when absolutely necessary; for example to get more metadata or data. The server only sends data that is needed by the user to maximize efficiency.
add a comment |Â
up vote
4
down vote
Aside from Jayant's excellent answer, it's worth noting that JavaScript is faster than Apex, hands-down. Whenever Visualforce started to have issues with rendering a page, the immediate solution is to use a client-side framework, as demonstrated in this answer. In other words, the general advice is to avoid using Apex, because it is slower than client-side rendering. Do as much as possible with client-side code.
This applies for both Visualforce and Lightning, but in particular, you'll enjoy a much more responsive UI if you do as much processing as you can after getting the data back from the Apex code. Apex should only be used to perform DML operations, callouts, and describes, with minimal processing and minimal server-side logic.
However, because of the nature of Lightning, do remember that Apex should still perform sanity checks, like making sure sharing is enforced, checking CRUD/FLS permissions, and generally ensuring that the request is not manipulated. Lightning mostly protects each name space from interacting with other namespaces, but it's not necessarily immune to poorly designed components that might be manipulated by external messages, etc.
add a comment |Â
up vote
0
down vote
You may also want to Evaluate out of the box lightning datatable component.
There won't be any need to maintain your table tags etc..
https://developer.salesforce.com/docs/component-library/bundle/lightning:datatable/example
add a comment |Â
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
5
down vote
Lightning Component Framework is optimized for performance. So unless and until you have things really going bad, you should be good if you implement your component using Lightning Components Performance Best Practices.
Then Lightning component framework is all about building rich UI applications utilizing more of client side features. So if you really donâÂÂt use the client side features, then you will end up under-utilizing the framework.
One of the significant considerations for performance in any framework is to reduce server trips. So as long as you are efficiently handling your client side components without making unwanted server calls, you are in fact doing it the right way.
Here are few of the excerpts which you can find on documentation on Lightning Component Framework.
The benefits include an out-of-the-box set of components, event-driven architecture, and a framework optimized for performance.
Uses a stateful client and stateless server architecture that relies on JavaScript on the client side to manage UI component metadata and application data. The client calls the server only when absolutely necessary; for example to get more metadata or data. The server only sends data that is needed by the user to maximize efficiency.
add a comment |Â
up vote
5
down vote
Lightning Component Framework is optimized for performance. So unless and until you have things really going bad, you should be good if you implement your component using Lightning Components Performance Best Practices.
Then Lightning component framework is all about building rich UI applications utilizing more of client side features. So if you really donâÂÂt use the client side features, then you will end up under-utilizing the framework.
One of the significant considerations for performance in any framework is to reduce server trips. So as long as you are efficiently handling your client side components without making unwanted server calls, you are in fact doing it the right way.
Here are few of the excerpts which you can find on documentation on Lightning Component Framework.
The benefits include an out-of-the-box set of components, event-driven architecture, and a framework optimized for performance.
Uses a stateful client and stateless server architecture that relies on JavaScript on the client side to manage UI component metadata and application data. The client calls the server only when absolutely necessary; for example to get more metadata or data. The server only sends data that is needed by the user to maximize efficiency.
add a comment |Â
up vote
5
down vote
up vote
5
down vote
Lightning Component Framework is optimized for performance. So unless and until you have things really going bad, you should be good if you implement your component using Lightning Components Performance Best Practices.
Then Lightning component framework is all about building rich UI applications utilizing more of client side features. So if you really donâÂÂt use the client side features, then you will end up under-utilizing the framework.
One of the significant considerations for performance in any framework is to reduce server trips. So as long as you are efficiently handling your client side components without making unwanted server calls, you are in fact doing it the right way.
Here are few of the excerpts which you can find on documentation on Lightning Component Framework.
The benefits include an out-of-the-box set of components, event-driven architecture, and a framework optimized for performance.
Uses a stateful client and stateless server architecture that relies on JavaScript on the client side to manage UI component metadata and application data. The client calls the server only when absolutely necessary; for example to get more metadata or data. The server only sends data that is needed by the user to maximize efficiency.
Lightning Component Framework is optimized for performance. So unless and until you have things really going bad, you should be good if you implement your component using Lightning Components Performance Best Practices.
Then Lightning component framework is all about building rich UI applications utilizing more of client side features. So if you really donâÂÂt use the client side features, then you will end up under-utilizing the framework.
One of the significant considerations for performance in any framework is to reduce server trips. So as long as you are efficiently handling your client side components without making unwanted server calls, you are in fact doing it the right way.
Here are few of the excerpts which you can find on documentation on Lightning Component Framework.
The benefits include an out-of-the-box set of components, event-driven architecture, and a framework optimized for performance.
Uses a stateful client and stateless server architecture that relies on JavaScript on the client side to manage UI component metadata and application data. The client calls the server only when absolutely necessary; for example to get more metadata or data. The server only sends data that is needed by the user to maximize efficiency.
edited 3 hours ago
answered 14 hours ago
Jayant Das
8,5502421
8,5502421
add a comment |Â
add a comment |Â
up vote
4
down vote
Aside from Jayant's excellent answer, it's worth noting that JavaScript is faster than Apex, hands-down. Whenever Visualforce started to have issues with rendering a page, the immediate solution is to use a client-side framework, as demonstrated in this answer. In other words, the general advice is to avoid using Apex, because it is slower than client-side rendering. Do as much as possible with client-side code.
This applies for both Visualforce and Lightning, but in particular, you'll enjoy a much more responsive UI if you do as much processing as you can after getting the data back from the Apex code. Apex should only be used to perform DML operations, callouts, and describes, with minimal processing and minimal server-side logic.
However, because of the nature of Lightning, do remember that Apex should still perform sanity checks, like making sure sharing is enforced, checking CRUD/FLS permissions, and generally ensuring that the request is not manipulated. Lightning mostly protects each name space from interacting with other namespaces, but it's not necessarily immune to poorly designed components that might be manipulated by external messages, etc.
add a comment |Â
up vote
4
down vote
Aside from Jayant's excellent answer, it's worth noting that JavaScript is faster than Apex, hands-down. Whenever Visualforce started to have issues with rendering a page, the immediate solution is to use a client-side framework, as demonstrated in this answer. In other words, the general advice is to avoid using Apex, because it is slower than client-side rendering. Do as much as possible with client-side code.
This applies for both Visualforce and Lightning, but in particular, you'll enjoy a much more responsive UI if you do as much processing as you can after getting the data back from the Apex code. Apex should only be used to perform DML operations, callouts, and describes, with minimal processing and minimal server-side logic.
However, because of the nature of Lightning, do remember that Apex should still perform sanity checks, like making sure sharing is enforced, checking CRUD/FLS permissions, and generally ensuring that the request is not manipulated. Lightning mostly protects each name space from interacting with other namespaces, but it's not necessarily immune to poorly designed components that might be manipulated by external messages, etc.
add a comment |Â
up vote
4
down vote
up vote
4
down vote
Aside from Jayant's excellent answer, it's worth noting that JavaScript is faster than Apex, hands-down. Whenever Visualforce started to have issues with rendering a page, the immediate solution is to use a client-side framework, as demonstrated in this answer. In other words, the general advice is to avoid using Apex, because it is slower than client-side rendering. Do as much as possible with client-side code.
This applies for both Visualforce and Lightning, but in particular, you'll enjoy a much more responsive UI if you do as much processing as you can after getting the data back from the Apex code. Apex should only be used to perform DML operations, callouts, and describes, with minimal processing and minimal server-side logic.
However, because of the nature of Lightning, do remember that Apex should still perform sanity checks, like making sure sharing is enforced, checking CRUD/FLS permissions, and generally ensuring that the request is not manipulated. Lightning mostly protects each name space from interacting with other namespaces, but it's not necessarily immune to poorly designed components that might be manipulated by external messages, etc.
Aside from Jayant's excellent answer, it's worth noting that JavaScript is faster than Apex, hands-down. Whenever Visualforce started to have issues with rendering a page, the immediate solution is to use a client-side framework, as demonstrated in this answer. In other words, the general advice is to avoid using Apex, because it is slower than client-side rendering. Do as much as possible with client-side code.
This applies for both Visualforce and Lightning, but in particular, you'll enjoy a much more responsive UI if you do as much processing as you can after getting the data back from the Apex code. Apex should only be used to perform DML operations, callouts, and describes, with minimal processing and minimal server-side logic.
However, because of the nature of Lightning, do remember that Apex should still perform sanity checks, like making sure sharing is enforced, checking CRUD/FLS permissions, and generally ensuring that the request is not manipulated. Lightning mostly protects each name space from interacting with other namespaces, but it's not necessarily immune to poorly designed components that might be manipulated by external messages, etc.
answered 13 hours ago
sfdcfox
235k10180396
235k10180396
add a comment |Â
add a comment |Â
up vote
0
down vote
You may also want to Evaluate out of the box lightning datatable component.
There won't be any need to maintain your table tags etc..
https://developer.salesforce.com/docs/component-library/bundle/lightning:datatable/example
add a comment |Â
up vote
0
down vote
You may also want to Evaluate out of the box lightning datatable component.
There won't be any need to maintain your table tags etc..
https://developer.salesforce.com/docs/component-library/bundle/lightning:datatable/example
add a comment |Â
up vote
0
down vote
up vote
0
down vote
You may also want to Evaluate out of the box lightning datatable component.
There won't be any need to maintain your table tags etc..
https://developer.salesforce.com/docs/component-library/bundle/lightning:datatable/example
You may also want to Evaluate out of the box lightning datatable component.
There won't be any need to maintain your table tags etc..
https://developer.salesforce.com/docs/component-library/bundle/lightning:datatable/example
answered 1 hour ago
apn
799829
799829
add a comment |Â
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsalesforce.stackexchange.com%2fquestions%2f237468%2fdoes-more-logic-on-client-side-reduces-the-lightning-performance%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password