'useState' is not defined no-undef React
You have forgotten to import useState
import React, { useEffect, useState } from "react";
You need to import "useState":
import React, { useEffect, useState } from "react";
I see that you have missed useState import.
Either you need to add like
import React, { useEffect, useState } from "react";
or make it React.useState
i.e.
const [state, setState] = React.useState({
joke: "",
});