Contact Number

+9501010103

Email Address

contact@oxosolutions.com

Social Icons
Empowering small to large businesses since 2008

Fulfilling all your IT needs at single stop
CIN: U74999PB2016PTC045616​GSTIN: ​​03AACCO3599B1ZO

Inline Small Javascript

Inline Small Javascript

Inline Javascript

When script tag is used in the HTML file, it is called inlined. This means no external JS file is used instead javascript is put into HTML file.

Why inline javascript?

It is recommended to inline javascript to lessen the number of javascript files that the browser needs to download before displaying the web page. 

The thing to consider is that most of the files are tiny and have a few lines of code. It is suggested to link such files to the HTML. 

How to inline Javascript?

You just need to copy the content of your external javascript file and paste them between the script tags of your HTML file.

<script>

YOUR JAVASCRIPT HERE

</script>

Benefits of Inline Javascript.

This is extremely advantageous as it can saves the web browser round trips to the server. This is because it no longer requires external file to download from the server-side.


Leave a Reply

Your email address will not be published. Required fields are marked *

Follow Us