import React, { useState, useEffect } from 'react' import { connect } from 'react-redux' import { deleteNotification, getUserNotifications } from '../../stores/exchange/duck/operations' import '../../styles/indexExchange.scss' const ExchangeNotifications = ({ user, exchange, deleteNotification, getUserNotifications }) => { useEffect( () => { getUserNotifications(user.id) }, [] ) const deleteOldNotification = (notifyID) => { let notify = { id: notifyID, token: user.token } deleteNotification(notify) } return (
{ user.login } exchange notifications:
{ key + 1 }. { notify.message }