score:0

Accepted answer

in component b you are destructuring value and setvalue from props but you are missing the curly braces {} you need to add curly braces like this.

           // add                    // add
const b = ({value: any, setvalue: any}) => {
    return (
        <input value={value} onchange={e => setvalue(e.target.value)}/>
    )
};

score:0

because parent component use param props same as {...prams} to pass it to child. let try:

const b = ({value: any, setvalue: any}) => {
    return (
        <input value={value} onchange={e => setvalue(e.target.value)}/>
    )
};

Related Query

More Query from same tag