<h1 dir="auto">Bug report</h1>
<h2 dir="auto">Describe the bug</h2>
<p dir="auto">Received this error without creating any viewport meta tag.<br>
And also no duplicate meta tag at client side.<br>
<code class="notranslate">Found conflicting amp tag "meta" with conflicting prop name="viewport". https://err.sh/next.js/conflicting-amp-tag</code></p>
<h2 dir="auto">To Reproduce</h2>
<ol dir="auto">
<li>start a new Next.js project</li>
<li>create <code class="notranslate">./pages/index.js</code> as below
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import { withAmp } from 'next/amp';

export default withAmp(() =&gt; {
  return &lt;div&gt;withAmp test&lt;/div&gt;
});"><pre class="notranslate"><code class="notranslate">import { withAmp } from 'next/amp';

export default withAmp(() =&gt; {
  return &lt;div&gt;withAmp test&lt;/div&gt;
});
</code></pre></div>
</li>
<li>create <code class="notranslate">./pages/_document.js</code> as below
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import React from 'react';
import Document, { Html, Head, Main, NextScript } from 'next/document';

export default class MyDocument extends Document {
  render() {
    return (
      &lt;Html&gt;
        &lt;Head /&gt;
        &lt;body&gt;
          &lt;Main /&gt;
          &lt;NextScript /&gt;
        &lt;/body&gt;
      &lt;/Html&gt;
    );
  }
}"><pre class="notranslate"><code class="notranslate">import React from 'react';
import Document, { Html, Head, Main, NextScript } from 'next/document';

export default class MyDocument extends Document {
  render() {
    return (
      &lt;Html&gt;
        &lt;Head /&gt;
        &lt;body&gt;
          &lt;Main /&gt;
          &lt;NextScript /&gt;
        &lt;/body&gt;
      &lt;/Html&gt;
    );
  }
}
</code></pre></div>
</li>
<li>yarn dev</li>
<li>received this error in the terminal<br>
<code class="notranslate">Found conflicting amp tag "meta" with conflicting prop name="viewport". https://err.sh/next.js/conflicting-amp-tag</code></li>
</ol>
<h2 dir="auto">Expected behavior</h2>
<p dir="auto">no error in the terminal</p>
<h2 dir="auto">System information</h2>
<ul dir="auto">
<li>OS: macOS</li>
<li>Browser: chrome</li>
<li>Version of Next.js: 8.1.0</li>
</ul>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/zeit/next.js/issues">issues</a> of this repository and believe that this is not a duplicate.</li>
</ul>
<p dir="auto">There is about 47% desktop browsers and about 45% mobile browsers run ES2015 without any problem. By <a href="https://www.netmarketshare.com" rel="nofollow">https://www.netmarketshare.com</a></p>
<p dir="auto">There is new simplest solution yet how to deploy separate javascript to modern browsers and transpiled to older browsers. And it is use to &lt;script type="module"&gt;<br>
Exists two nice articles how to use it<br>
<a href="https://philipwalton.com/articles/deploying-es2015-code-in-production-today/" rel="nofollow">https://philipwalton.com/articles/deploying-es2015-code-in-production-today/</a><br>
<a href="https://www.contentful.com/blog/2017/04/04/es6-modules-support-lands-in-browsers-is-it-time-to-rethink-bundling/" rel="nofollow">https://www.contentful.com/blog/2017/04/04/es6-modules-support-lands-in-browsers-is-it-time-to-rethink-bundling/</a></p>
<p dir="auto">Both articles explains how to do that with webpack and script tag.<br>
This could be really nice feature, because half of all visitors don't need to transpile to older code.</p>
<p dir="auto">What we need to make it work?</p>
<ol dir="auto">
<li>babel-plugin-transform-es2015-modules-commonjs no needed anymore</li>
<li>Replace UglifyJs with Babel Minify (Babili)</li>
<li>Create new webpack entry and common plugins</li>
<li>Set two different babelrc settings for ES2015 and for legacy</li>
<li>Create two different script tags explained in blog articles</li>
</ol>