Async & Defer Loading
Contents hide

Async Vs Defer JS Loading: Frequently Asked Questions

Async Vs Defer JavaScript

Async Vs Defer Loading is an important part of web development that allows us to load resources in parallel instead of sequentially. This helps improve performance by reducing the amount of time spent waiting for resources to download.

Why Should I Care About Async Vs Defer Loading?

If you’re building websites, you should care about Async & Defer because it’s one of the most important things you can do to make your website faster. It’s also very easy to implement!

What is Render Blocking?

The process in which the web resources (ex: JS, CSS & HTML files) that are loaded in the webpage potentially cause the browser to block the rendering of the page until they are loaded is called as render-blocking. It is because these web files can be large with hundreds of kilobytes of data that must be loaded, in addition to the HTML, before it is rendered.  Therefore, always look for the best solution to eliminate render-blocking resources in above-the-fold content and optimize CSS delivery. Two techniques that are widely used are async & defer Loading.

What are Render-blocking JavaScripts?

JavaScripts that block the rendering of meaningful content are called ‘Render Blocking JavaScripts’. They need to be either deferred or use async.

What is Critical JavaScripts?

JavaScripts files that are necessary to load during optimized critical rendering.

What is Non-critical JavaScripts?

JavaScript files that can wait to load until the first meaningful content (the first paint) of the webpage have loaded are called as non-critical javascript.

What is Inline Delivery?

Inline delivery refers to load a resource (ex: like JS, CSS) within the HTML code instead of calling/importing that separately.

How to Remove Render Blocking JavaScripts from my website?

To remove render-blocking JavaScripts, developers need to inline critical JavaScript and defer all non-critical JavaScript.

What is that one common thing both async and defer have?

Both async and defer have one common thing. That is, downloading of render-blocking javascript doesn’t block page rendering. So the visitors may read webpage content & get acquainted with the webpage immediately.

Why Should We Defer Loading of JavaScripts?

When the web browser comes across a javascript, it executes the script first before continue to load HTML that includes the content users are looking for. It means that JavaScripts are one of the major culprits to make your website slow.

Further, For a browser, executing a JavaScript is a heavier task as it depends on the size of the javascript. Also, it takes more time as compared to render the meaningful content (the first paint) of the webpage.

Hence JavaScript affects the critical rendering path and slows down page speed of your site. Also, defer loading heavier task of JS execution so that critical rendering path remain uninterrupted.

How to identify Render-Blocking JavaScripts on your website?

Render-Blocking JavaScript(s) of your website can be identified by using site speed testing tools.

There are several page speed testing tools available to analyze a website for site speed and loading time. The most reliable and trusted tools for page speed testing are

1. PageSpeed Insights by Google
2. GTmetrix
3. Pingdom Tools

Test your website using the above speed testing tools. And analyze the results of these tools so that you can compare the results before and after implementing defer parsing of JavaScript(s).

What does defer mean in JavaScript?

Defer literally means ‘hold back’ or ‘delay’. If you use ‘defer’ attribute in <script> for parsing (loading) of JavaScript, JavaScript will execute only after the HTML parsing has finished. This helps to improve the speed of a webpage.

Does async Vs defer loading attributes have any effect on inline scripts?

No, both async & defer attributes don’t have any effect on inline scripts.

What is Defer Parsing of JavaScript?

Usually, Googe Pagespeed Insights (PSI) or other site speed testing tools (GTMetrix, etc.) show warning/error “”, if your website loads JavaScript(s) that block the loading of meaningful content (the first paint) of your site.

According to Google PageSpeed Insights (PSI) recommendations, your website should deliver critical JS inline and defer all non-critical JS.

Therefore, defer parsing of JavaScript means JavaScript(s) should load, only after the content of the website has loaded.

What is the Main Reason to Defer Loading of JavaScript?

As u know,  the browser gives priority to execute the scripts over parsing the HTML. However, the fact is, most of the JavaScripts are used only when the complete web page is loaded. Examples are animation, effect, or some functionality, etc.

Therefore, it is a good idea to load JavaScript(s) only after the content has been loaded.

What are the advantages of deferred loading of JavaScript?

There are two main reasons why you would use async & defer: performance and accessibility.

The other advantages of deferred loading of JavaScript are

1. It deferred loading of JavaScript does not affect the critical render path

2. It consequently helps to speed up your website.

3. It gives a better user experience to your website visitors.

4. It makes your site load faster

5. It helps improve your search ranking on desktop as well as mobile.

6. It helps improve the performance of websites.

7. It allows the elimination of render-blocking JavaScript.

What is defer parsing?

Whenever a browser encoun­ters a javascript with the defer attribute, it will follow the below steps sequentially.

  1. First, make par­al­lel requests to fetch the indi­vid­ual files.
  2. Meanwhile, Con­tinue pars­ing the doc­u­ment as if it was never interrupted.
  3. Then, Fin­ish task of pars­ing the web doc­u­ment even if the javascript files are downloaded.
  4. Once the task of parsing documents is finished, Exe­cute each script in the order they were encoun­tered in the document.

Ex: <script src=”myjavascriptfile1.js” defer></script>
<script src=”myjavascriptfile2.js” defer></script>

Therefore, Defer is very sim­i­lar to async attribute with just one major dif­fer­er­ence.

How do you defer JavaScript?

With HTML V5, two new boolean attributes for the <script> tag has been introduced. They are async and defer. Async attribute allows the execution of javascript files asynchronously. but, defer attribute allows execution only after the whole document has been parsed.

The webpage would have to load and execute scripts before finishing to render the page.

Here’s a usage example of defer attribute of <script>:

<script defer src=”/js/jquery.min.js”> </script>

How to Defer Loading of JavaScript in WordPress?

You can defer parsing of JavaScript in WordPress by following three methods:

  1. Using WordPress Plugins.
  2. Using the Script method (without using plugins).
  3. Adding a Code Snippet to function.php file.

What are the advantages of the async loading of JavaScript?

Advantages of async loading of JavaScript are

0. It allows the elimination of render-blocking JavaScript.

1. async loading of JavaScript does not affect the critical render path.

2. It consequently helps to speed up your website.

3. It gives a better user experience to visitors of websites.

4. It makes your website load faster.

5. It helps to improve your search ranking on desktop as well as mobile.

6. It helps to improve the performance of websites.

How do you async attribute in JavaScript?

When you add the async attribute to your script tag, the fol­low­ing steps likely will happen.

  1. It makes par­al­lel requests to fetch the files.
  2. It con­tinue parsing/loading the doc­u­ment as if it was never interrupted.
  3. Exe­cute the indi­vid­ual scripts the moment the java files are downloaded.

Ex: <script src=”javascript1.js” async></script>
<script src=”javascript1.js” async></script>

What is the main difference between async & defer loading?

async and defer are similar in that they allow scripts to load without blocking the HTML parsing. It means users see page content more quickly. But they do have differences too.

Here are the main difference between async and defer JavaScript

1. The defer attribute delays JavaScript execution until HTML parsing has completed. Whereas with async attribute HTML parsing & script execution happens simultaneously and the script executes as soon as it’s ready.

2. Scripts loaded with async are parsed and executed immediately when the resource is done downloading.     Whereas scripts with defer attributee don’t execute until the HTML doc is done being parsed.

3. async scripts may load out-of-order, whereas defer scripts are executed in the order in which they appear in the markup.

4. async follows Load-first order. Here the order of document doesn’t matter. It may load and execute while the document has not yet been fully downloaded. It also happens if scripts are small or cached, and the document is long enough. whereas defer follows Document order (as they go in the document). That is it executes after the document is loaded and parsed (they wait if needed), right before DOMContentLoaded.

Why prefer Defer over Async?

Though Both async and defer cause JavaScript execution to happen at different times on the web page.

defer causes javascript execution to happen at the same time as or later than async. It is because javascripts are made defer or async & are less important for the critical content on the webpage. Therefore, it’s better to use defer so that their execution happens outside of the main rendering time.

defer scripts can never block synchronous scripts. Whereas async scripts depend on how quickly they download. Synchronous scripts are typically made synchronous because they are important for the critical content on the webpage.

Therefore, it’s always better to use defer so that synchronous scripts are not blocked from executing. Also, their critical work is completed more quickly.

Which is better async Vs defer Loading?

While using with an async attribute, the JavaScript file gets downloaded asynchronously & then executed as soon as it’s downloaded.

Whereas with the defer attribute, the file gets downloaded asynchronously. But executed only when the document loading is completed. Also, scripts will execute in the same order as they are called.

Let’s take an example. Assume we are using jQuery as well as other javascript that depend on it. Now, We use defer on them (jQuery included), making sure to call jQuery before the dependent scripts.

Therefore, defer is the right choice of attribute when a script depends on another script. And, defer is the right choice when async is not an option.

How To Add Async Vs Defer Loading Scripts To A WordPress Page Or Post?

If you’re using a CMS such as WordPress, Joomla, Drupal, etc., then you can add async & defer scripts to any page or post. This will make sure that the script loads after the rest of the page has loaded.

How To Add Asynch And Defer Scripts To An Individual HTML File?

There are two ways to add async & defer scripts. First, you can use an external JavaScript file. Second, you can add them directly into the HTML code. 

How To Add Async Vs Defer Loading Scripts To A Custom Theme?

If you’re using WordPress, there are some plugins that will help you add async & defer scripts to your website. However, if you’re not using WordPress, you can add async & defer scripts by adding them directly into the HTML

What are the 5 Ways To Defer Loading On Your Website?

The term “deferring” means delaying something until later in order to save money or resources. For example, you might defer buying a new car because you’re saving for retirement instead. Or you might defer paying for an item until next month so that you have enough cash flow to pay for it.

Load Time Is A Ranking Factor In Search Engines.

If you’ve ever noticed how slow some websites load, you’ll understand why Google has been emphasizing speed as a ranking factor in search engines. It’s not just a matter of aesthetics; it also affects user experience.

The Faster Your Site Loads, The More Visits You’ll See.

In fact, according to a study by Google, users who visit sites with fast load times tend to stay longer than those who visit slower sites. That means faster site loads result in more visits.

There Are Several Ways To Reduce Page Weight.

If you’re looking to reduce the weight of your pages, there are several ways to do so. Here are some of the most common methods:
1) Minify CSS and JavaScript files – This will compress the size of these files, making them smaller and easier to download.
2) Combine multiple stylesheets into one – This will combine multiple stylesheets into a single file, reducing the number of requests made to the server.
3) Remove unused images – Images take up a lot of space, especially when they aren’t used. Removing unused images can help save bandwidth and improve performance.

Here’s One Simple Way To Speed Things Up.

There are also other ways to speed things up, such as using compression software to shrink the size of images before uploading them to your site.

This Is Another Easy Way To Cut Down On Page Weight.

If you’re looking for an easy way to cut down on page weight, there are plenty of options available. One of the easiest ways to do so is by using CSS sprites. A sprite is simply a collection of multiple images that are combined into one image file. It’s a quick and easy way to reduce the number of requests needed to load a web page.

What are the Top 5 Async Loading Examples for E-Commerce Sites?

Asynchronous loading is an essential part of modern web development. It allows developers to load content in parallel without blocking the main thread. This improves performance for users and makes the site feel faster.Asynchronous loading is an important technique used by e-commerce sites to improve user experience. In this article, we’ll show you five examples of asynchronous loading on e-commerce websites.

The Amazon App Store

Amazon has been using asynchronous loading since 2012. They use it to display product images as soon as they are available, rather than waiting until the entire image loads before displaying it.

Apple Music

Apple Music uses asynchronous loading to load more music. This means that when users scroll down, new songs will start playing without having to wait for the previous ones to finish loading.

Facebook Messenger

If you use Facebook Messenger as a customer service platform, you should consider using asynchronous loading to make your customers feel more comfortable with your brand.

Instagram Stories

Instagram Stories and Snapchat Stories are two different ways to share photos and videos. Both platforms allow users to post short videos and photos that disappear after 24 hours. However, there are some differences between these two apps.

Pinterest

While both Instagram and Snapchat offer similar features, there are some key differences between them. For example, Instagram allows users to add text to their images while Snapchat does not. Also, Instagram has a feature called “Stories” where users can upload multiple photos and videos at once. This feature is not available on Snapchat.

How to do Defer JavaScript for Better User Experience?

Defer JavaScript is an important technique for improving user experience on websites. It allows web developers to load scripts asynchronously so they don’t slow down page rendering. Defer Javascript is an important technique for increasing performance on websites. It allows developers to load scripts asynchonrously so that they don’t slow down the page rendering.

Why Should You Defer Scripts?

There are several reasons why you should defer scripts. First, deferring scripts will improve the speed of your website by reducing the number of HTTP requests. Second, deferring scripts will reduce the size of your HTML document. Third, deferring scripts will allow users to view more pages without waiting for scripts to finish loading. Fourth, deferring scripts will help prevent errors caused by script conflicts. Finally, deferring scripts will make your site easier to use because it will eliminate the need to reload the page when scripts fail.

When Should You Defer Script Loading?

To determine whether or not to defer scripts, you must first understand how scripts work. A script is a piece of code that runs automatically when a webpage loads. This means that every time a visitor visits your site, a new copy of the script is loaded into memory. If you have multiple scripts on a page, each one will take up space in memory. In addition, there’s a limit to the number of scripts that can be loaded at once. So, if you have too many scripts on a page, some visitors might see a “script error” message instead of seeing the rest of the page.

How Do You Defer Scripts In Practice?

There are two ways to defer scripts: using the async attribute and using the defer attribute. Both methods accomplish the same thing, but use different syntax.

Is There Any Consequences To Not Deferring Scripts?

If you’re not familiar with deferring scripts, there’s no reason to worry. In fact, deferring scripts is one of the best practices for improving performance on websites.

Why Should You Defer JavaScript?

There are two main reasons why you should defer JavaScript. First, deferring scripts will improve the speed at which your website loads. Second, deferring scripts will reduce the number of HTTP requests needed to render your pages.

What are the Top 5 Benefits of Using Asynchronous JavaScript In Your Websites?

Asynchronous JavaScript allows web developers to create more responsive websites by loading content asynchronously. Asynchronous JavaScript allows web pages to load faster because the browser doesn’t need to wait for all the code on a page to finish before displaying the page. This technique also makes it easier to update parts of a website without having to reload the entire page.

This means that the browser will load other resources before it loads the current page.

There are two main ways to use asynchronous JavaScript: using script tags with async attributes and using XHR2 (XMLHttpRequest 2).

Load Images First.

Loading images first will improve performance because browsers load them before text. This means that users won’t see any blank space while waiting for the image to load.

Load CSS Last.

If you want to make sure that your website loads quickly, then you should load CSS last. This ensures that the browser has enough time to download all of the other files needed to display your site properly.

Load Scripts Second.

Loading scripts second means that the browser will start downloading them before any images or stylesheets. This makes your site load faster because the browser won’t need to wait for those assets to load first.

Load HTML Third.

If you’re using asynchronous JavaScript, make sure you load your HTML last so that the browser has enough time to download everything else.

What are the 4 Ways to Make Your Site Faster with Asynchronous JavaScript?

Asynchronous JavaScript is a technique for writing scripts that run in parallel with the rest of the web page. This means that when the script finishes running, the browser will continue loading the rest of the page. Asynchronous JavaScript allows us to write code that doesn’t block the browser from rendering other content on the page. It also makes our site faster by allowing the browser to load more pages while we’re still working on one.

Load Images asynchronously.

There’s no need to wait until an image has loaded before continuing to render the page. Instead, use the async attribute to tell the browser to start loading images as soon as possible.

Minify JavaScript.

Minifying JavaScript removes unnecessary characters from the source code, making it smaller and easier to download. This reduces the number of bytes sent across the network and speeds up the page load times.

Cache static assets.

If you’ve ever visited a website that loads slowly, you’ll know how frustrating it can be. One of the reasons why sites take so long to load is because they send large amounts of data across the network. Static files such as images, CSS, and JavaScript are cached by the browser, meaning that when you visit the same URL again, the browser will retrieve the file directly from its cache instead of sending requests to the server.

Use Web Workers.

In addition to caching static files, web browsers also cache asynchronous JavaScript calls. This means that when you make an AJAX call, the browser will wait until the request has completed before continuing to render the rest of the page. By using web workers, however, you can tell the browser to execute some JavaScript code without waiting for the response.

Load scripts asynchronously.

To use asynchronous JavaScript, we need to add a script tag to the head of our document. We then need to set async=”true” so that the browser knows not to wait for the script to finish loading before continuing to render the page.

Deferred Loading Issues

Deferred loading occurs when you try to log in to your account, but you’re unable to do so because of a problem with your computer or network connection. When you have an issue with deferred loading, you may not be able to access your account or see your orders. We’ll show you how to fix it!

Check your browser’s settings.

If you’re having trouble logging into your account, check your browser’s settings. You might need to adjust some options, such as clearing your cache or cookies.

Clear your cache.

To clear your cache, go to your browser’s menu bar and select “tools” > “clear browsing data.” Then click “OK”. This will remove any temporary files that were used to store information while you browsed the web.

Try another browser.

If you’re still having issues clearing your cache, try using a different browser. You might also need to restart your computer.

Restart your computer.

Sometimes, when you clear your cache, you may find that your computer needs to be restarted before you can log back into your account. This is because some browsers store data locally so that they can load faster.

Reset your password.

If you’re having trouble logging in, resetting your password will help you regain access to your account. You can do this by going to https://www.youtube.com/account/passwordreset and entering your email address and username.

5 Ways To Make Your Website More User-Friendly

The term “deferred script” refers to a set of instructions that will be executed when a visitor clicks a link on your website. For example, if you’re selling products online, you might include a link in an email message that says something like, “Click here for free shipping.” When someone clicks that link, the instructions inside the email message are executed.
There are many ways to implement deferred scripts on your site. In this article, we’ll show you five different methods.

Defer Scripts with JavaScript.

If you’ve ever used Google Analytics, you’ve probably seen how easy it is to defer scripts. You simply add a line of code to your web pages that tells the browser to execute the script after the page has loaded. This allows you to load scripts asynchronously, meaning they won’t slow down your page’s loading speed.

Defer Scripts Using CSS.

One of the easiest ways to defer scripts is by using CSS. Simply add a class name to any element that contains JavaScript. Then, use the @media rule to specify when the script should run.

Defer Scripts With HTML.

If you’re not familiar with how to do this, here’s an easy way to make sure your website loads faster. Simply add a class to any element that contains scripts. Then, use the media query to specify when the script will load.

Defer Scripts Through Server Side Includes (SSI).

This method uses server side includes (SSI) to defer loading of JavaScript files until after the HTML has been parsed by the browser. It works well for small sites where there are only a few pages. However, it does require some technical knowledge to set up correctly.

Defer Scripts By Adding an Statement.

If you’re using Apache as your web server, you can use the mod_include module to add SSIs to your website. You can also use PHP’s include() function to do the same thing. Both of these options will allow you to defer script execution until after the HTML document has been loaded.

7 Benefits of Using Deferred Scripts

Deferred scripts allow you to load JavaScript after the page has loaded. The defer attribute allows you to delay loading JavaScript until later in the page load process. This helps improve performance by reducing the number of HTTP requests that need to be made.

This means you don’t have to wait until the end of the document to start loading scripts.

You can use the defer attribute to load JavaScript at any point during the page load process. However, there are some situations where using deferred scripts isn’t ideal. If you’re loading scripts dynamically (i.e., not statically), then you’ll need to add the defer attribute to each script tag.

Load JavaScript Faster.

Loading JavaScript faster means more time spent on other tasks. This includes things like reading articles, watching videos, browsing social media sites, etc. It also means less time spent waiting for pages to load.

Reduce Page Size.

If you’re using deferred scripts, you should consider reducing the size of the script file. You can do this by removing unnecessary code and comments.

Increase Performance.

Deferred scripts also improve performance because they reduce the number of HTTP requests made to the server. This means fewer round trips between the browser and the server, which improves response times.

Minimize HTTP Requests.

If you use deferred scripts, make sure to only load them when needed. You should never load a script before the page loads. Doing so will slow down the loading process and cause unnecessary HTTP requests.

Advantages of Asynchronous JavaScript

The term “asynchronous” refers to the fact that JavaScript code executes in an order different from the order in which it was written. This means that JavaScript code can execute before other parts of the page load, allowing for faster loading times. Here are the advantages of asynchronous JavaScript.

Here’s what you need to know about it.

There are two main ways to make sure that JavaScript loads asynchronously: using the async attribute and using script tags with defer.

The Benefits of Asynchronous JavaScript

Using the async attribute allows developers to specify when scripts should load. This means that scripts will not block the loading of other HTML elements on the page. It also prevents users from having to wait while scripts load before continuing to use the site.

Why You Should Be Using Asynchronous JavaScript

There are several reasons why you should be using asynchronous JavaScript. First, it makes your website more responsive by allowing the browser to continue rendering the page without waiting for scripts to finish loading. Second, it helps prevent users from having to wait for scripts to load before continuing to use your site. Third, it improves performance because it reduces the number of HTTP requests made to the server. Fourth, it makes your site easier to maintain because it keeps code organized into separate files. Finally, it makes your site more secure because it prevents malicious script attacks.

When to Use Asynchronous JavaScript

If you need to make an AJAX request to a remote server, then you should use asynchronous JavaScript. However, there are times when you shouldn’t use asynchronous JavaScript. For instance, if you are making an AJAX request to retrieve data from a local database, then you should not use asynchronous JavaScript.

Common Mistakes with Asynchronous JavaScript

There are several common mistakes that people make when using asynchronous JavaScript. One mistake is to assume that every browser supports asynchronous JavaScript. In fact, some browsers do support asynchronous JavaScript, while others do not. Another mistake is to assume that asynchronous JavaScript will improve performance. This isn’t necessarily true. Sometimes, asynchronous JavaScript can actually slow down the loading of web pages.

Asynchronous vs Synchronous JavaScript

There are two ways to execute code on the page: synchronously or asynchronously. Learn more about them here! Asynchronous execution means that JavaScript will continue executing other parts of the page while waiting for an event to occur. This makes it possible to load content faster, but also introduces potential problems when trying to use multiple asynchronous functions in the same script.

Synchronous Code Execution

In contrast, synchronous code execution means that JavaScript pauses until the function has completed before moving on to the next line of code. This is typically used for things like form validation, where you need to wait for the user to submit the form before continuing with the rest of the page.

Asynchronous Code Execution

Asynchronous code execution allows JavaScript to continue executing while other parts of the page load. It’s often used for things like animations, where you want to keep the page loading faster by not waiting for the animation to complete before moving on to the rest of the page (or even navigating away).

Why Defer JavaScript Is Necessary for Your Website

You may have heard about deferred JavaScript loading but don’t know why it’s necessary. In this article, we’ll explain what it is and why it’s important. Deferred JavaScript loading allows web pages to load faster by delaying the execution of scripts until after all other content has been loaded. This technique is used in many modern websites, including Facebook and Twitter.

The Benefits of Deferred Loading

There are several benefits to using deferred loading. First, it makes your website more responsive because it loads scripts asynchronously, meaning that the script will not block the browser from rendering any other content. Second, it reduces the number of HTTP requests made by your site. Third, it improves performance because it prevents the browser from downloading unnecessary scripts. Finally, it helps reduce bandwidth usage because it only downloads scripts when needed.

When Should You Load JavaScript?

To determine whether you should load JavaScript synchronously or asynchronously, consider these questions:
1. How much does the script add to the size of your HTML document? If the script adds little to no extra bytes to your HTML file, then it’s better to defer its loading.
2. Does the script require additional resources such as images or CSS files? If so, then it’s better not to defer the script’s loading.
3. Are there any events that trigger the script to run? If so, then deferring the script’s loading is preferable.

How to Load JavaScript

There are two ways to load JavaScript asynchronously: using an asynchronous script tag and using a script loader.

How Do I Add Deferred Scripting to My Site?
There are two ways to add deferring scripts to your site. One method involves using an HTML tag called

If you're not familiar with how to use these techniques, you should read our previous articles on them first. They will help you understand the basics of both approaches.

10 Reasons Why Async JavaScript Is Necessary For Your Website

Asynchronous JavaScript allows your website to load faster and more efficiently. The asynchronous nature of JavaScript means that when a user clicks on a link in your web page, the browser will start loading the new content before continuing to load the rest of the page. This makes it possible to display information while other parts of the page load.

Here's why it's important.

If you're building a website with a lot of dynamic content, such as news articles, blog posts, or social media feeds, then you need to use asynchronous JavaScript.

Load Time Matters.

Loading times matter because people expect websites to load quickly. In fact, according to Google, users will leave a site after only 3 seconds if it takes longer than 5 seconds to load. This means that if your website loads slowly, visitors will likely abandon it before they even see what it has to offer.

Faster Loading Means More Conversions.

One of the biggest reasons why people visit your website is to find out how much it costs. If your website takes too long to load, then you might lose potential customers who decide not to purchase anything.

The Future Of Web Design.

In addition to being fast, websites should also be responsive. Responsive web design (RWD) means that your site will adapt to any screen size. This makes it easier for users to navigate your site and use your services.

Mobile First.

If you’re building a new website, you need to make sure that it loads quickly and looks good on mobile devices. You can do this by using asynchronous JavaScript.

Async Vs Defer Loading Javascript: Top 5 Interesting FAQs