Skip to content

Instantly share code, notes, and snippets.

View parham-ab's full-sized avatar
💭

Parham Abolghasemi parham-ab

💭
View GitHub Profile
@mortezashojaei
mortezashojaei / OrdersComponent.tsx
Last active August 8, 2024 02:50
Using laravel-echo in reactjs
import React, { FC } from 'react';
import { useSocket } from '@myapp/hooks';
import {Order} from '@myapp/models';
export const OrdersComponent: FC = () => {
const [orders,setOrders] = useState<Order[]>();
function addNewOrder(neworder:Order) {