import React, {useState, useRef} from 'react'; function SECAPIData() { const [filedAt, setFiledAt] = useState(""); const [xml, setXML] = useState(""); const requestData = () => { const toSend = { filedAt : filedAt, xml : xml, }; let axiosConfig = { headers: { 'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8', "Access-Control-Allow-Origin": "*", } }; axios({ method: 'post', url: 'http://localhost:4567/', headers: axiosConfig, data: toSend }) .then(response => { }) .catch(function (error) { console.log(error); }); } return (