title: How to detect if browser is compatible with ES2015
body: <p>I have a big chunk of JS libraries that I should rewrite since it's really old and outdated. So, I decided to come up with a solution where I would just use most of <em>ES2015</em> features like <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/rest_parameters">rest parameters</a>.</p>
  
  <p>The thing is, I am sure all the clients would not have their browser up-to-date and I am confused whether I will face any issue regarding their browser is compatible with my new JS libs.</p>
  
  <p>So, I was wondering if I could detect whether the client browsers are compatible with ES2015. And if not, I would just include my old JS library.</p>
  
  <p>I am looking for a solution like <a href="http://www.quirksmode.org/css/condcom.html">Conditional comments</a>, but I am getting nowhere to solution.</p>
  
  <p>Any help in HTML, JS or PHP is appreciated. Please kindly suggest your advice.</p>