title: Javascript notification when accessing an undefined object property
body: <p>I think Javascript is trying to kill me. Errors that would be caught by a compiler in any statically-typed language including FORTRAN, or turn into a run-time exception in any decent dynamically-typed language are swallowed silently by Javascript, patiently waiting to manifest as a bug elsewhere.</p>
  
  <p>Whenever we write Frontend code (nowadays with Angular), we spend most of our time hunting down mistakes such as writing <code>$scope.result = data.results</code> instead of <code>data.result</code> . While some tools help, it still requires an astonishing amount of work.</p>
  
  <p>Is there a way to cause the Javascript environment (in a browser) to log a warning whenever someone tries to read a non-existing object property? I don't want to change the language's semantics - accessing <code>data.results</code> should still returned <code>undefined</code>, I just want to see a warning on the console saying "Non-existing property accessed, file ... line ...".</p>