import { connect } from "react-redux";

const Nick = ({ nick }) => {
  return (
    <>
      <div>
        <p>{nick}</p>
      </div>
    </>
  );
};

const ConnectNickName = connect((state) => ({
  nick: state?.auth?.payload?.sub?.login || 0,
}))(Nick);
export default ConnectNickName;
