Add proptypes, remove unused imports
This commit is contained in:
1 parent
8b87bf3c9e
commit
a11202d612
2 files changed
+6
-4
No files matched your search
@@ -11,6 +11,7 @@ import "./index.css";
|
||||
import Button from "../../Components/Button";
|
||||
import { useNavigate } from "react-router";
|
||||
import { getLastChecked } from "../../Utils/monitorUtils";
|
||||
import PropTypes from "prop-types";
|
||||
|
||||
const Card = ({ data }) => {
|
||||
const theme = useTheme();
|
||||
@@ -57,6 +58,10 @@ const Card = ({ data }) => {
|
||||
);
|
||||
};
|
||||
|
||||
Card.propTypes = {
|
||||
data: PropTypes.object.isRequired,
|
||||
};
|
||||
|
||||
/**
|
||||
* Renders a skeleton layout.
|
||||
*
|
||||
@@ -129,7 +134,7 @@ const PageSpeed = () => {
|
||||
);
|
||||
useEffect(() => {
|
||||
dispatch(getPageSpeedByUserId(authToken));
|
||||
}, []);
|
||||
}, [authToken, dispatch]);
|
||||
|
||||
// will show skeletons only on initial load
|
||||
// since monitor state is being added to redux persist, there's no reason to display skeletons on every render
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
import Fallback from "../../Components/Fallback";
|
||||
import { useTheme } from "@emotion/react";
|
||||
|
||||
const Status = () => {
|
||||
const theme = useTheme();
|
||||
|
||||
return (
|
||||
<div className="status">
|
||||
<Fallback
|
||||
|
||||
Reference in new issue
Block a user