Saketh Kowtha
Articles by @sakethk

Articles by @sakethk

Benefit of maintaining separate Javascript file in HTML

Saketh Kowtha
·Jul 3, 2021·

1 min read

Subscribe to my newsletter and never miss my upcoming articles

Play this article

The benefit of a separate file is that the browser will download it and store it in its cache. So the Other pages that reference the same script will take it from the cache instead of downloading it, so the file is actually downloaded only once. This reduces traffic and makes pages faster.

 
Share this