title: Rewrite conditions and rules in Virtual host or .htaccess? Which is preferred?
body: <p>I am using <code>apache 2.4</code> and hosting an <code>angular2</code> application. I have written the <code>rewrite rules and conditions</code> in my virtual host itself, but I wonder if I should use an <code>.htaccess</code> file. What are the benefits of using one over the other?</p>
  
  <blockquote>
    <p>Edit: Added .htaccess</p>
  </blockquote>
  
  <p>I tried with the implementation of <code>.htaccess</code> for angular2 and it seems that I have to manually paste the <code>.htaccess</code> in the <code>dist</code> folder. Which would be bad. But still, I ask this for a generic application. Which configuration should be preferred? Do the configuration in <code>virtual host</code> or have a separate <code>.htaccess</code>?</p>