Best javascript function ever

function javascriptEnabled(){
     return true;
}

Source
That is all.


Related posts:

  1. Spartan Coding
  2. On naming functions sanely
  3. A couple useful jQuery Snippets
  4. Using the jQuery-UI Autocomplete Widget
  5. Documenting PHP Code

Tags: , , , , , , , ,

  • http://twitter.com/nicluciano Nic

    How can I check before I call? Clearly some recursion is necessary here. ;)

    • http://seanja.com/blog SeanJA

      Obviously you put this in your function to test if javascript is working:


      function myFunction(){
      if(!javascriptEnabled()){
      alert('Oh no! You don't have javascript enabled, we cannot continue.');
      }
      }

      :P