title: Access to fetch at 'http://localhost:6969/graphql' from origin 'http://localhost:3000' has been blocked by CORS policy:
body: <p>This is reamining part of error -&gt; <em>No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.</em></p>
  <p>I am learning Graphql with React js with help of Apollo Client ,
  This is my Server.js Code :-</p>
  <pre><code>const express = require(&quot;express&quot;);
  const app = express();
  const PORT = 6969;
  const userData = require(&quot;./MOCK_DATA.json&quot;);
  const schema = require(&quot;./Schemas/index.js&quot;)
  const graphql = require(&quot;graphql&quot;);
  
  const {
      GraphQLObjectType,
      GraphQLSchema,
      GraphQLInt,
      GraphQLString,
      GraphQLList
  } = graphql
  const {graphqlHTTP} = require('express-graphql')
  
   
  app.use('/graphql', graphqlHTTP({
      schema,
      graphiql: true
  }))
  
  
  app.listen(PORT, () =&gt; {
      console.log(&quot;Server Running&quot;);
  })
  </code></pre>
  <p>This is my App.js File To show Fetched Data :-</p>
  <pre><code>import React from 'react';
  import './App.css';
  import { ApolloClient, InMemoryCache, ApolloProvider, HttpLink, from } from '@apollo/client'
  import {onError} from '@apollo/client/link/error';
  import GetUser from './Components/GetUser';
  
  
  const errorLink = onError(({ graphqlErrors, networkError }) =&gt; {
    if (graphqlErrors) {
      graphqlErrors.map(({ message, location, path }) =&gt; {
        alert(`Graphql error ${message}`);
      });
    }
  });
  
  const link = from([
    errorLink,
    new HttpLink({ uri: &quot;http://localhost:6969/graphql&quot; }),
  ]);
  
  const client = new ApolloClient({
    cache: new InMemoryCache(),
    link: link,
  });
  
  function App() {
    return (
      &lt;ApolloProvider client={client }&gt;
        &lt;GetUser/&gt;
      &lt;/ApolloProvider&gt;
    );
  }
  
  export default App;
  </code></pre>