DEV Community

Cover image for JavaScript Performance Optimization

JavaScript Performance Optimization

Sonay Kara on October 15, 2024

If you like my articles, you can buy me a coffee :) JavaScript Performance Optimization Most of us write code with JavaScript. Howeve...
Collapse
 
bridget_amana profile image
Bridget Amana

Thanks for this👍

Collapse
 
sonaykara profile image
Sonay Kara

You're welcome! I'm glad you found it helpful!

Collapse
 
ibrahim-mc profile image
Ibrahim Faisal

Bravo! Short and nice 👍🏼

Collapse
 
sonaykara profile image
Sonay Kara

Thank you! Your feedback means a lot to me. I'm glad you enjoyed the article!. ositive feedback like this motivates me to keep writing

Collapse
 
aadswebdesign profile image
Aad Pouw

About const/let, make const first choice and as soon it has to be reassigned make it let. In case it happens that you forget, you will be reminded by the browser's dev.
Also, work modular. That way you can slice the cake in managable and reusable pieces.

Collapse
 
sonaykara profile image
Sonay Kara

you are right, In objects and arrays, using const prevents the reference from being changed, but allows the values within them to be modified.

Collapse
 
kvv_6a29738da825fadf4e0d9 profile image
Kvv

Tnx for this , so usefull

Collapse
 
sonaykara profile image
Sonay Kara

Thank you! Your feedback means a lot to me. I'm glad you enjoyed the article!. ositive feedback like this motivates me to keep writing

Collapse
 
kvv_6a29738da825fadf4e0d9 profile image
Kvv

Keep it up cheif

Collapse
 
hr_recruitment_kanak profile image
HR Recruitment

Very valuable and informative content. Keep writing. Nice guys .....

Collapse
 
sonaykara profile image
Sonay Kara

Thank you very much for your valuable feedback! I'm glad you found the article useful. Support from readers motivates me to continue creating more content.

Collapse
 
gorathean profile image
gorathean

Event should only be removed when the element will no longer be used right?

Collapse
 
sonaykara profile image
Sonay Kara

Yes. It is important for performance to only remove event listeners when the element is no longer used or unnecessary. unnecessary event listeners can cause memory leaks

Collapse
 
vikkio88 profile image
Vincenzo

this is a silly collection of old fashioned tips, is this generated with ai?

Collapse
 
sonaykara profile image
Sonay Kara

This isn't a silly collection of old fashioned tips. Try to be respectful. Wasn't it generated with ai. If you have a better idea, you can share it.