Unable to fetch POST without no-cors in header
<p>On making request like that:</p>

<pre><code>return fetch(
            'http://localhost:8000/login',
            {   method: 'POST',
                headers: new Headers(
                   {"Content-Type": "application/json",
                    "Accept":"application/json"}
                ),

                body: JSON.stringify(
                   {'name': 'Tom', 'password': 'Soyer'}
                )
             }
           ).then( response =&gt; { console.log(response);})
            .catch(err =&gt; console.log(err))
</code></pre>

<p>request running with method OPTIONS instead POST.
Only on adding mode: 'no-cors' request become POST:</p>

<pre><code>return fetch(
            'http://localhost:8000/login',
            {   method: 'POST',
                mode: 'no-cors',
                headers: new Headers(
                   {"Content-Type": "application/json",
                    "Accept":"application/json"}
                ),
                body: JSON.stringify(
                   {'name': 'Tom', 'password': 'Soyer'}
                )
             }
           ).then( response =&gt; { console.log(response);})
            .catch(err =&gt; console.log(err))
</code></pre>

<p>but response not ok than (even if network response status is 200): {type: "opaque", url: "", status: 0, ok: false, statusText: ""…}
I suppose it because </p>

<blockquote>
  <p>The only allowed values for the Content-Type header are:
  application/x-www-form-urlencoded multipart/form-data text/plain</p>
</blockquote>

<p>described here <a href="https://developer.mozilla.org/en-US/docs/Web/HTTP/Access_control_CORS" rel="noreferrer">https://developer.mozilla.org/en-US/docs/Web/HTTP/Access_control_CORS</a></p>

<p>Is any way bring to live POST json data with fetch?</p>