title: Ember.js Utility Class
body: <p>I am new to Ember.js and Javascript in general. I am using <a href="http://www.ember-cli.com/">ember-cli</a> to create an app that could use a DateUtil class to perform some date manipulation. I noticed that ember-cli has a utilities generator to produce the following boilerplate code in app/utils/date-util.js:</p>
  
  <pre><code>export default function dateUtil() {};
  </code></pre>
  
  <p>I am wondering how to write a utility so that I can use it across my application. Specifically, as an example, in a controller:</p>
  
  <pre><code>export default Ember.ObjectController.extend({
    startDate: dateUtil.thisMonday()
  });
  </code></pre>
  
  <p>where thisMonday() would return the date of this Monday using moment.js like:</p>
  
  <pre><code>moment({hour:0}).day(1);
  </code></pre>
  
  <p>There would be many others similar to thisMonday() as part of dateUtil.</p>