Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7923503
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T17:20:48+00:00 2026-06-03T17:20:48+00:00

While using javascript in developing ,say a photo blog where you retrieve all the

  • 0

While using javascript in developing ,say a photo blog where you retrieve all the images from a folder and display it in all unique ways or making an ajax call to retrieve data from server and load it with all styling and logic applied on the fly (or any thing that involves hard hitting js code that spans hundreds of lines or even thousands), what are all the areas that JS developers concentrate on making the code more efficient (in terms of performance).

For instance we come across a lot of online galleries. what would be the first thing that would be the concern of a js developer if he has to load like 50 images from his server on to the website. I am pulling this up just to make an instance of JS code having to deal with quite good amount of data.

The thing that I am looking for is, I am currently involved in JS development and when I write medium(or large) js applications what should I be concentrating for improving performance.

  1. In terms of memory used?
  2. In terms of making loops efficient?
  3. In terms of using 3rd party frameworks like Jquery or Dojo?
  4. In terms of design and Algo used (I guess there is always this option open)

Any suggestions in writing a more efficient JS code would be of great help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T17:20:50+00:00Added an answer on June 3, 2026 at 5:20 pm

    Performance tuning is very, very application specific. As Donald Knuth says,

    We should forget about small efficiencies, say about 97% of the time: premature optimization is the root of all evil

    Generally, the best idea is to write your application and then figure out what you need to optimize as you go. Application takes too long to load? Use a minifier and defer loading of heavy resources (such as images). Too much CPU usage? Maybe you’re updating the DOM too frequently instead of in batches. You won’t know until you have a working sample, and then profile it.

    Third party libraries are a great tool for getting a prototype up and working quickly. The cons are generally 1) Their payload can be large, increasing load time (though this can be mitigated by using CDNs/caching), 2) They make it a lot easier to do things that can be CPU intensive, because it hides so much of what is going on. Though this is only an issue if you are having CPU issues anyway, which is not always the case (and hard to know ahead of time without profiling).

    Everytime you modify the DOM, the browser has to reflow and figure out how the page should be rendered with your change. This is why it is recommended that you use CSS classes to modify/change styles, because they can be changed in a single go, where-as stacking style changes means reflow for every attribute you are changing.

    There are a great deal of these types of JS performance tips floating around. What it all boils down to is what your actual working example is showing you based on the profiler (such as that available in Chrome development tools) as well as the user experience.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

while working on a school project i ran into a problem using javascript to
I'm developing a web UI using GWT. While working only with the widgets I
While using ubercart I need to insert some javascript tracking codes to the order
While developing a design using jQuery I stumbled across a problem. How would I
While developing my app (asp.net mvc3) locally everything was fine using the VS dev
While developing a website, firebug threw me a javascript error linking to the execution
I've been thinking of developing a web application using HTML and JavaScript for a
I have made a set of HTML5 pages using Jquery mobile. While developing I
I am facing a strange issue while using javascript setTimeout function in IE8. I
I've been using javascript for a while, but have never learned the language past

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.