Download Javascript only, if supported

I do not want my users to upload a ton of JS files if their browser does not support it. What is the best / easiest / fastest to only load JS scripts if the browser supports Javascript?

Thanks in advance - JS noob

+3
source share
1 answer

If JavaScript is disabled, the browser will not download files from the srctag attribute <script type='text/javascript'>.

+6
source

Source: https://habr.com/ru/post/1729601/


All Articles