projeto-hit/frontend/src/services/socket.js

6 lines
197 B
JavaScript
Raw Normal View History

import { io } from 'socket.io-client';
// "undefined" means the URL will be computed from the `window.location` object
const URL = process.env.REACT_APP_BACKEND_URL
export const socket = io(URL);