parent component:
import React from "react";
import InputRow from "./InputRow";
const Bid: React.FunctionComponent = () => {
const inpVal = (d:string) => {
}
return (
<div style={{ display: "none" }} className="bid-container animated zoomIn" id="bid-modal">
  <p>Mortage</p>
  <div className="bid-row-container">
    <p>Enter your bid</p>
    <div className="bid-row">
      <InputRow bid="Bid" inpVal={(inpVal: string)=>{console.log(inpVal)}} />
    </div>
  </div>
</div>
);
};
export default Bid;
child component:
import React from "react";
interface Props{
bid: string,
inpVal: (inpVal:string) => void;
}
const InputRow: React.FunctionComponent<Props> = (bid, inpVal) => {
 return (
<div className="input-row">
  <div>
    <input type="text"  onChange={(e) => { inpVal(e.target.value) }} />
    <p>Rate</p>
  </div>
  <button className="bid-btn">{bid.bid}</button>
</div>
);
};
 export default InputRow;
I am trying to pass the input value from the child component to the parent component but it is throwing error.
TypeError: inpVal is not a function.
 
     
    