title: How many classes per module
body: <p><strong>How many classes/functions are best put into a module</strong> (which is later <code>require</code>d, f.ex. by <a href="http://requirejs.org/" rel="nofollow noreferrer">RequireJS</a>, the <a href="https://developer.mozilla.org/en-US/Add-ons/SDK/Low-Level_APIs/_loader" rel="nofollow noreferrer">Mozilla addon loader</a>, ...)?</p>
  
  <p>As the module seems to be imported wholesale (contrary to f.ex. Python, where you can do <code>from module import class</code>), would it be best to keep them as small as possible? Any other guidelines?</p>
  
  <p>What is the best practice?</p>
  
  <p>(There are similar questions about <a href="https://stackoverflow.com/questions/312642/how-many-classes-per-package-methods-per-class-lines-per-method">Java</a> (which recommends <a href="https://stackoverflow.com/a/17927021/1587329">"the more granular class layout you have, the better"</a>),  <a href="https://stackoverflow.com/questions/8061930/python-one-class-per-module-and-packages">Python</a> (which allows for more objects and states <a href="https://stackoverflow.com/a/8062064/1587329">"Python is not C#/Java. Trying to bend it to make it look like <code>$other_language</code> will cause frustration and poor user experience"</a>) , etc, but nothing JavaScript-specific appeared.)</p>
  
  <hr>
  
  <p>Maybe these questions were old enough to pass the site standards then. Nowadays, it might be really too broad for some.</p>