Componentize myform, myinput and call to API