diff --git a/src/components/RandomMsg.jsx b/src/components/RandomMsg.jsx
index 9863c39..c5d2b64 100644
--- a/src/components/RandomMsg.jsx
+++ b/src/components/RandomMsg.jsx
@@ -1,39 +1,51 @@
+import { useState, useEffect } from "react";
import { API_URL } from "../config";
-import { default as $ } from "jquery";
-import ReplayIcon from '@mui/icons-material/Replay';
-
-
-var randomMsg;
-
-const getRandomMsg = () => {
- $.ajax({
- url: API_URL+'/randmsg',
- method: "POST",
- contentType: "application/json; charset=utf-8"
- }).done(function (data) {
- if (! data.msg) {
- return;
- } else {
- randomMsg = data.msg.replace("
", "\n");
- $('.random-msg').html(`${randomMsg}`);
- }
- });
-}
+import ReplayIcon from "@mui/icons-material/Replay";
export default function RandomMsg() {
- getRandomMsg();
- return (
-