Neo4j websocket error

I am using NeoVis to connect to the DB and display a graph.
However, my react app is throwing the following error:
Neo4jError: WebSocket connection failure. Due to security constraints in your web browser, the reason for the failure is not available to this Neo4j Driver. Please use your browsers development console to determine the root cause of the failure. Common reasons include the database being unavailable, using the wrong connection URL or temporary network problems. If you have enabled encryption, ensure your browser is configured to trust the certificate Neo4j is configured to use. WebSocket readyState is: 3

I tried the app using the movies database from neo4j to check if my server config is wrong, but I get the same error.

Here is the code:
import React, { useEffect, useRef } from 'react';
import NeoVis from 'neovis.js';

const NeoVisComponent = () => {
const visRef = useRef(null);

useEffect(() => {
const config = {
container_id: 'neo4j-vis',
server_url: 'neo4j+s://demo.neo4jlabs.com',
server_user: 'movies',
server_password: 'movies',
labels: {

  },
  relationships: {
   
  },
};

const vis = new NeoVis(config);

const cypherQuery = 'MATCH (n:Movie) RETURN n LIMIT 25'

vis.renderWithCypher(cypherQuery)

return () => {
  console.log("Yes")
};

}, );

return (


);
};

export default NeoVisComponent;

Also does anyone know if I need to add the server_url as proxy in package.json?

I am running into the same issue. Did you solve this?