I tend to use the following method.
1) displays a default error message
<div id="noJS">For use, you need JavaScript enabled. (nice images and perhaps a link to your fav. browser)</div>
2) disable it via javascript and show the main application container
$("#noJS").hide(); $("#app").show();
If javascript is only needed for, for example, navigation, you should try to provide a non-js version for non-js users to increase your audience.
Phil rykoff
source share