title: AngularJS ignoring whitespace in string
body: <p>I am having hard time finding out how can I get AngularJS not to ignore whitespaces in strings. Im trying to validate password requirements with AngularJS directive and regex pattern and problem is that I dont want to allow leading or trailing whitespace in password.</p>
  
  <p>Here is fiddle <a href="http://jsfiddle.net/GX5Kr/9/" rel="nofollow">http://jsfiddle.net/GX5Kr/9/</a></p>
  
  <pre><code>var regex = /^(?=.*[0-9])(?=.*[a-zA-Z])([a-zA-Z0-9]{5,})$/;
  </code></pre>